Skip to content

Commit 6181b29

Browse files
committed
bump Rust
1 parent 669b9ea commit 6181b29

File tree

2 files changed

+4
-5
lines changed

2 files changed

+4
-5
lines changed

rust-version

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
nightly-2018-11-20
1+
nightly-2018-11-21

src/fn_call.rs

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -469,10 +469,9 @@ impl<'a, 'mir, 'tcx: 'mir + 'a> EvalContextExt<'tcx, 'mir> for super::MiriEvalCo
469469
instance,
470470
promoted: None,
471471
};
472-
let const_val = self.const_eval(cid)?;
473-
let value = const_val.unwrap_bits(
474-
self.tcx.tcx,
475-
ty::ParamEnv::empty().and(self.tcx.types.i32)) as i32;
472+
let const_val = self.const_eval_raw(cid)?;
473+
let const_val = self.read_scalar(const_val.into())?;
474+
let value = const_val.to_i32()?;
476475
if value == name {
477476
result = Some(path_value);
478477
break;

0 commit comments

Comments
 (0)