Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Consider exposing Builder::attrs publically #21

Open
Phantomical opened this issue Nov 7, 2022 · 2 comments
Open

Consider exposing Builder::attrs publically #21

Phantomical opened this issue Nov 7, 2022 · 2 comments

Comments

@Phantomical
Copy link
Contributor

This crate doesn't cover the entire surface of the perf_event_open API and with things like dynamic PMUs it's not really possible for it to cover all use cases. It would be nice if Builder::attrs was exposed publically so that downstream crates could modify them directly.

@jimblandy
Copy link
Owner

As an unsafe method, sure.

@PoignardAzur
Copy link

Seconded. Being able to pass a custom value to attrs.config would be super helpful.

Not sure it would need to be unsafe, though. Unsafe implies "there are certain invariants you need to uphold to make sure your code is sound", but in this case I don't see what the invariants would be.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants