Skip to content

Restore Signal::from_raw as Signal::from_named_raw.#1406

Merged
sunfishcode merged 3 commits intomainfrom
sunfishcode/raw-named-signals
Mar 16, 2025
Merged

Restore Signal::from_raw as Signal::from_named_raw.#1406
sunfishcode merged 3 commits intomainfrom
sunfishcode/raw-named-signals

Conversation

@sunfishcode
Copy link
Member

Rust 1.0 moved Signal::from_raw into a separate crate, since properly supporting SIGRTMIN+n signals requires querying libc. But it's still useful to have a version of this function in rustix which is just documented to not support SIGRTMIN+n signals, so re-introduce it, with a different name and with appropriatet documentation.

@sunfishcode sunfishcode added enhancement New feature or request and removed enhancement New feature or request labels Mar 9, 2025
Rust 1.0 moved `Signal::from_raw` into a [separate crate], since
properly supporting `SIGRTMIN+n` signals requires querying libc. But
it's still useful to have a version of this function in rustix which
is just documented to not support `SIGRTMIN+n` signals, so re-introduce
it, with a different name and with appropriatet documentation.

[separate crate]: https://crates.io/crates/rustix-libc-wrappers
@sunfishcode sunfishcode force-pushed the sunfishcode/raw-named-signals branch from 9af49c5 to f2048c5 Compare March 16, 2025 03:20
@sunfishcode
Copy link
Member Author

This is restoring the functionality that previously was provided by Signal::from_raw, so I've now added a CHANGES.md entry for it.

@sunfishcode sunfishcode changed the title Add a Signal::from_named_raw constructor. Restore Signal::from_raw as Signal::from_named_raw. Mar 16, 2025
@sunfishcode sunfishcode merged commit 4bc94ab into main Mar 16, 2025
51 checks passed
@sunfishcode sunfishcode deleted the sunfishcode/raw-named-signals branch March 16, 2025 03:33
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

Successfully merging this pull request may close these issues.

1 participant