-
Notifications
You must be signed in to change notification settings - Fork 1.1k
adding pid_type enum for Linux. #4403
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
Conversation
Oh I see yes I ll try it out a bit later, so by quick glancing it, we can t choose the underlying type of the values right ? |
The macro for this should expand to pub type pid_type = c_uint;
pub const PIDTYPE_PID: pid_type = 0;
pub const PIDTYPE_TGID: pid_type = 1
// etc; I made it accept |
2b93449
to
b7fe45c
Compare
src/unix/linux_like/linux/mod.rs
Outdated
@@ -92,6 +92,16 @@ e! { | |||
} | |||
} | |||
|
|||
c_enum! { | |||
e { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This identifier is the name of the type alias, so should be pid_type
here. I should add some docs...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
of course ... thanks :)
b7fe45c
to
e79c8d9
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
[ref](https://github.com/torvalds/linux/blob/7cdabafc001202de9984f22c973305f424e0a8b7/include/linux/pid_types.h#L5) (cherry picked from commit e79c8d9) (backport <rust-lang#4403>)
[ref](https://github.com/torvalds/linux/blob/7cdabafc001202de9984f22c973305f424e0a8b7/include/linux/pid_types.h#L5) (cherry picked from commit e79c8d9) (backport <rust-lang#4403>)
[ref](https://github.com/torvalds/linux/blob/7cdabafc001202de9984f22c973305f424e0a8b7/include/linux/pid_types.h#L5) (backport <rust-lang#4403>) (cherry picked from commit e79c8d9)
[ref](https://github.com/torvalds/linux/blob/7cdabafc001202de9984f22c973305f424e0a8b7/include/linux/pid_types.h#L5) (backport <rust-lang#4403>) (cherry picked from commit e79c8d9)
ref