diff options
| author | Martin Nordholts <enselic@gmail.com> | 2022-10-24 20:14:28 +0200 |
|---|---|---|
| committer | Martin Nordholts <enselic@gmail.com> | 2022-10-24 20:40:46 +0200 |
| commit | 5e624bf4bad3156f63ca95702b7bd6246751ded5 (patch) | |
| tree | cb1cd5639338feb0ec6165e1a71b9004a103b288 | |
| parent | c07a6a9c0c6c571d535de74d7ec28469fba46e37 (diff) | |
| download | rust-5e624bf4bad3156f63ca95702b7bd6246751ded5.tar.gz rust-5e624bf4bad3156f63ca95702b7bd6246751ded5.zip | |
rustdoc: Use `unix_sigpipe` instead of `rustc_driver::set_sigpipe_handler`
Start using `unix_sigpipe` instead of `rustc_driver::set_sigpipe_handler`. After this has been merged, we can completely remove `rustc_driver::set_sigpipe_handler`. Verification of this change --------------------------- 1. Remove `#[unix_sigpipe = "sig_dfl"]` 1. Run `./x.py build` 1. Run `./build/aarch64-apple-darwin/stage1/bin/rustdoc --help | false` 1. Observe ICE 1. Add back `#[unix_sigpipe = "sig_dfl"]` 1. Run `./x.py build` 1. Run `./build/aarch64-apple-darwin/stage1/bin/rustdoc --help | false` 1. Observe ICE fixed
| -rw-r--r-- | src/librustdoc/lib.rs | 1 | ||||
| -rw-r--r-- | src/tools/rustdoc/main.rs | 3 |
2 files changed, 3 insertions, 1 deletions
diff --git a/src/librustdoc/lib.rs b/src/librustdoc/lib.rs index 793061a9f7a..4cf9435d9c8 100644 --- a/src/librustdoc/lib.rs +++ b/src/librustdoc/lib.rs @@ -154,7 +154,6 @@ pub fn main() { } } - rustc_driver::set_sigpipe_handler(); rustc_driver::install_ice_hook(); // When using CI artifacts (with `download_stage1 = true`), tracing is unconditionally built diff --git a/src/tools/rustdoc/main.rs b/src/tools/rustdoc/main.rs index 5b499a1fa1f..b81f46d1211 100644 --- a/src/tools/rustdoc/main.rs +++ b/src/tools/rustdoc/main.rs @@ -1,3 +1,6 @@ +#![feature(unix_sigpipe)] + +#[unix_sigpipe = "sig_dfl"] fn main() { rustdoc::main() } |
