Skip to content

Commit 2661295

Browse files
committed
error code E0080 is no longer printed with MIRI error message
1 parent 22d0546 commit 2661295

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

src/eval.rs

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ use rustc::ty::{self, TyCtxt};
99
use syntax::source_map::DUMMY_SP;
1010

1111
use crate::{
12-
struct_error, EnvVars, Evaluator, FnVal, HelpersEvalContextExt, InterpCx, InterpError,
12+
EnvVars, Evaluator, FnVal, HelpersEvalContextExt, InterpCx, InterpError,
1313
InterpResult, MemoryExtra, MiriMemoryKind, Pointer, Scalar, StackPopCleanup, Tag,
1414
TlsEvalContextExt,
1515
};
@@ -221,7 +221,10 @@ pub fn eval_main<'tcx>(tcx: TyCtxt<'tcx>, main_id: DefId, config: MiriConfig) {
221221
};
222222

223223
let msg = format!("Miri evaluation error: {}", msg);
224-
let mut err = struct_error(ecx.tcx.tcx.at(span), msg.as_str());
224+
let mut err = {
225+
let new_tcx = ecx.tcx.tcx.at(span);
226+
new_tcx.sess.struct_span_err(new_tcx.span, msg.as_str())
227+
};
225228
let frames = ecx.generate_stacktrace(None);
226229
err.span_label(span, msg);
227230
// We iterate with indices because we need to look at the next frame (the caller).

0 commit comments

Comments
 (0)