diff options
| author | Dylan DPC <99973273+Dylan-DPC@users.noreply.github.com> | 2022-11-05 11:31:28 +0530 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-11-05 11:31:28 +0530 |
| commit | bd9e6e05d2d15ea2a41e890c5e3ee9ccc7e6cd48 (patch) | |
| tree | fed2e3e69f196ff95fdedb9ea4578f50ad639e2e /compiler/rustc_codegen_ssa/src/back | |
| parent | 3450aa38d0af7264bb5eb5450880ab82e87b051f (diff) | |
| parent | 71a3a48ee52a5cbc3fa3e3e8d322ebeb97ed109f (diff) | |
| download | rust-bd9e6e05d2d15ea2a41e890c5e3ee9ccc7e6cd48.tar.gz rust-bd9e6e05d2d15ea2a41e890c5e3ee9ccc7e6cd48.zip | |
Rollup merge of #103660 - ozkanonur:master, r=jyn514
improve `filesearch::get_or_default_sysroot` `fn get_or_default_sysroot` is now improved and used in `miri` and `clippy`, and tests are still passing as they should. So we no longer need to implement custom workarounds/hacks to find sysroot in tools like miri/clippy. Resolves https://github.com/rust-lang/rust/issues/98832 re-opened from #103581
Diffstat (limited to 'compiler/rustc_codegen_ssa/src/back')
| -rw-r--r-- | compiler/rustc_codegen_ssa/src/back/link.rs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/compiler/rustc_codegen_ssa/src/back/link.rs b/compiler/rustc_codegen_ssa/src/back/link.rs index 6f0a8d0a54c..5a1ad792924 100644 --- a/compiler/rustc_codegen_ssa/src/back/link.rs +++ b/compiler/rustc_codegen_ssa/src/back/link.rs @@ -1123,7 +1123,8 @@ fn link_sanitizer_runtime(sess: &Session, linker: &mut dyn Linker, name: &str) { if path.exists() { return session_tlib; } else { - let default_sysroot = filesearch::get_or_default_sysroot(); + let default_sysroot = + filesearch::get_or_default_sysroot().expect("Failed finding sysroot"); let default_tlib = filesearch::make_target_lib_path( &default_sysroot, sess.opts.target_triple.triple(), |
