replaced some map_or with map_or_else
This commit is contained in:
parent
5ff1be197e
commit
c75c4a579b
12 changed files with 82 additions and 70 deletions
|
@ -50,7 +50,7 @@ fn eval_body_using_ecx<'mir, 'tcx>(
|
|||
|
||||
let name =
|
||||
with_no_trimmed_paths(|| ty::tls::with(|tcx| tcx.def_path_str(cid.instance.def_id())));
|
||||
let prom = cid.promoted.map_or(String::new(), |p| format!("::promoted[{:?}]", p));
|
||||
let prom = cid.promoted.map_or_else(|| String::new(), |p| format!("::promoted[{:?}]", p));
|
||||
trace!("eval_body_using_ecx: pushing stack frame for global: {}{}", name, prom);
|
||||
|
||||
ecx.push_stack_frame(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue