about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--.travis.yml8
-rw-r--r--miri/bin/miri.rs4
-rw-r--r--rustc_tests/src/main.rs4
-rw-r--r--src/librustc_mir/interpret/validation.rs17
4 files changed, 10 insertions, 23 deletions
diff --git a/.travis.yml b/.travis.yml
index d42ef2287af..86577702e96 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -16,9 +16,9 @@ script:
   xargo/build.sh
 - |
   # Test plain miri
-  cargo build --locked --release --features "cargo_miri" &&
-  cargo test --release --all &&
-  cargo install --features "cargo_miri"
+  cargo build --locked --release --all-features &&
+  cargo test --locked --release --all-features --all &&
+  cargo install --locked --all-features
 - |
   # Test cargo miri
   cd cargo-miri-test &&
@@ -27,7 +27,7 @@ script:
   cd ..
 - |
   # and run all tests with full mir
-  MIRI_SYSROOT=~/.xargo/HOST cargo test --release
+  MIRI_SYSROOT=~/.xargo/HOST cargo test --locked --release
 - |
   # test that the rustc_tests binary compiles
   cd rustc_tests &&
diff --git a/miri/bin/miri.rs b/miri/bin/miri.rs
index 9b8790379d8..65f855a513f 100644
--- a/miri/bin/miri.rs
+++ b/miri/bin/miri.rs
@@ -11,6 +11,7 @@ extern crate syntax;
 extern crate log;
 
 use rustc::session::Session;
+use rustc::middle::cstore::CrateStore;
 use rustc_driver::{Compilation, CompilerCalls, RustcDefaultCalls};
 use rustc_driver::driver::{CompileState, CompileController};
 use rustc::session::config::{self, Input, ErrorOutputType};
@@ -64,11 +65,12 @@ impl<'a> CompilerCalls<'a> for MiriCompilerCalls {
         &mut self,
         matches: &getopts::Matches,
         sess: &Session,
+        cstore: &CrateStore,
         input: &Input,
         odir: &Option<PathBuf>,
         ofile: &Option<PathBuf>,
     ) -> Compilation {
-        self.default.late_callback(matches, sess, input, odir, ofile)
+        self.default.late_callback(matches, sess, cstore, input, odir, ofile)
     }
     fn build_controller(
         &mut self,
diff --git a/rustc_tests/src/main.rs b/rustc_tests/src/main.rs
index d1f2f07aaaa..819721c1cd0 100644
--- a/rustc_tests/src/main.rs
+++ b/rustc_tests/src/main.rs
@@ -13,6 +13,7 @@ use std::io;
 
 
 use rustc::session::Session;
+use rustc::middle::cstore::CrateStore;
 use rustc_driver::{Compilation, CompilerCalls, RustcDefaultCalls};
 use rustc_driver::driver::{CompileState, CompileController};
 use rustc::session::config::{self, Input, ErrorOutputType};
@@ -52,11 +53,12 @@ impl<'a> CompilerCalls<'a> for MiriCompilerCalls {
         &mut self,
         matches: &getopts::Matches,
         sess: &Session,
+        cstore: &CrateStore,
         input: &Input,
         odir: &Option<PathBuf>,
         ofile: &Option<PathBuf>
     ) -> Compilation {
-        self.default.late_callback(matches, sess, input, odir, ofile)
+        self.default.late_callback(matches, sess, cstore, input, odir, ofile)
     }
     fn build_controller(&mut self, sess: &Session, matches: &getopts::Matches) -> CompileController<'a> {
         let mut control = self.default.build_controller(sess, matches);
diff --git a/src/librustc_mir/interpret/validation.rs b/src/librustc_mir/interpret/validation.rs
index 251bd71ffce..23bb0d8dbb7 100644
--- a/src/librustc_mir/interpret/validation.rs
+++ b/src/librustc_mir/interpret/validation.rs
@@ -398,23 +398,6 @@ impl<'a, 'tcx, M: Machine<'tcx>> EvalContext<'a, 'tcx, M> {
             }
         }
 
-        // HACK: For now, bail out if we hit a dead local during recovery (can happen because sometimes we have
-        // StorageDead before EndRegion due to https://github.com/rust-lang/rust/issues/43481).
-        // TODO: We should rather fix the MIR.
-        match query.lval.1 {
-            Lvalue::Local { frame, local } => {
-                let res = self.stack[frame].get_local(local);
-                match (res, mode) {
-                    (Err(EvalError { kind: EvalErrorKind::DeadLocal, .. }),
-                     ValidationMode::Recover(_)) => {
-                        return Ok(());
-                    }
-                    _ => {}
-                }
-            }
-            _ => {}
-        }
-
         query.ty = self.normalize_type_unerased(&query.ty);
         trace!("{:?} on {:?}", mode, query);