diff options
| author | Guillaume Gomez <guillaume1.gomez@gmail.com> | 2021-02-26 15:52:31 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-02-26 15:52:31 +0100 |
| commit | 039b1b62acc736080d3ecf86c249f00356ac91a0 (patch) | |
| tree | 06a59887bed652640e0c2294ab8f0287038203c5 /compiler/rustc_codegen_ssa/src/back | |
| parent | a56bbb134fe98931de92b587c3b98920f6923bc9 (diff) | |
| parent | 08b1e8004b06112fb8334155b2cea314bd3e8161 (diff) | |
| download | rust-039b1b62acc736080d3ecf86c249f00356ac91a0.tar.gz rust-039b1b62acc736080d3ecf86c249f00356ac91a0.zip | |
Rollup merge of #82456 - klensy:or-else, r=estebank
Replaced some unwrap_or and map_or with lazy variants Replaced some `unwrap_or` and `map_or` with `unwrap_or_else` and `map_or_else`.
Diffstat (limited to 'compiler/rustc_codegen_ssa/src/back')
| -rw-r--r-- | compiler/rustc_codegen_ssa/src/back/link.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/rustc_codegen_ssa/src/back/link.rs b/compiler/rustc_codegen_ssa/src/back/link.rs index 08932e26bf1..caa6a6a8e3a 100644 --- a/compiler/rustc_codegen_ssa/src/back/link.rs +++ b/compiler/rustc_codegen_ssa/src/back/link.rs @@ -2082,7 +2082,7 @@ fn add_upstream_rust_crates<'a, B: ArchiveBuilder<'a>>( let filestem = cratepath.file_stem().unwrap().to_str().unwrap(); cmd.link_rust_dylib( Symbol::intern(&unlib(&sess.target, filestem)), - parent.unwrap_or(Path::new("")), + parent.unwrap_or_else(|| Path::new("")), ); } } |
