Auto merge of #833 - RalfJung:win, r=RalfJung

reenable all tests on Windows
This commit is contained in:
bors 2019-07-11 17:01:14 +00:00
commit b5ddc94bf0
3 changed files with 4 additions and 15 deletions

View file

@ -31,20 +31,11 @@ pub fn create_ecx<'mir, 'tcx: 'mir>(
main_id: DefId,
config: MiriConfig,
) -> InterpResult<'tcx, InterpCx<'mir, 'tcx, Evaluator<'tcx>>> {
// FIXME(https://github.com/rust-lang/miri/pull/803): no validation on Windows.
let target_os = tcx.sess.target.target.target_os.to_lowercase();
let validate = if target_os == "windows" {
false
} else {
config.validate
};
let mut ecx = InterpCx::new(
tcx.at(syntax::source_map::DUMMY_SP),
ty::ParamEnv::reveal_all(),
Evaluator::new(),
MemoryExtra::new(config.seed.map(StdRng::seed_from_u64), validate),
MemoryExtra::new(config.seed.map(StdRng::seed_from_u64), config.validate),
);
let main_instance = ty::Instance::mono(ecx.tcx.tcx, main_id);

View file

@ -725,8 +725,8 @@ pub trait EvalContextExt<'mir, 'tcx: 'mir>: crate::MiriEvalContextExt<'mir, 'tcx
this.write_null(dest)?;
}
// We don't support threading.
"pthread_create" => {
// We don't support threading. (Also for Windows.)
"pthread_create" | "CreateThread" => {
return err!(Unimplemented(format!("Miri does not support threading")));
}

View file

@ -111,9 +111,7 @@ fn run_pass_miri(opt: bool) {
}
fn compile_fail_miri(opt: bool) {
if !cfg!(windows) { // FIXME re-enable on Windows
compile_fail("tests/compile-fail", &get_target(), opt);
}
compile_fail("tests/compile-fail", &get_target(), opt);
}
fn test_runner(_tests: &[&()]) {