diff options
| author | Dylan DPC <dylan.dpc@gmail.com> | 2020-05-16 02:37:23 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-05-16 02:37:23 +0200 |
| commit | 040e242168ffc0f5674ea02692c8c4a2f99f7f77 (patch) | |
| tree | 7da3a71552d630e078d169ca730f40a0ae897b08 /src/test/debuginfo/enum-thinlto.rs | |
| parent | badcf267df6ecfc62a765eea0e03d1ccf0cd3d02 (diff) | |
| parent | 51e466de3cbfb94b7d0736066a765d8ea31394e4 (diff) | |
| download | rust-040e242168ffc0f5674ea02692c8c4a2f99f7f77.tar.gz rust-040e242168ffc0f5674ea02692c8c4a2f99f7f77.zip | |
Rollup merge of #72090 - RalfJung:rustc_driver-exit-code, r=oli-obk
rustc_driver: factor out computing the exit code In a recent Miri PR I [added a convenience wrapper](https://github.com/rust-lang/miri/pull/1405/files#diff-c3d602c5c8035a16699ce9c015bfeceaR125) around `catch_fatal_errors` and `run_compiler` that @oli-obk suggested I could upstream. However, after seeing what could be shared between `rustc_driver::main`, clippy and Miri, really the only thing I found is computing the exit code -- so that's what this PR does. What prevents using the Miri convenience function in `rustc_driver::main` and clippy is that they do extra work inside `catch_fatal_errors`, and while I could abstract that away, clippy actually *computes the callbacks* inside there, and I fond no good way to abstract that and thus gave up. Maybe the clippy thing could be moved out, I am not sure if it ever can actually raise a `FatalErrorMarker` -- someone more knowledgeable in clippy would have to do that.
Diffstat (limited to 'src/test/debuginfo/enum-thinlto.rs')
0 files changed, 0 insertions, 0 deletions
