about summary refs log tree commit diff
diff options
context:
space:
mode:
authorOliver Scherer <github35764891676564198441@oli-obk.de>2019-05-26 15:27:04 +0200
committerOliver Scherer <github35764891676564198441@oli-obk.de>2019-08-05 17:48:05 +0200
commit7385f2177f8e3b66ec8f506ed8ec9689460a9b85 (patch)
treecc85618bbf4a505577d2ee4b8f42b842648f81af
parent2d86d040a5472998843008cbb6ffa58de0fd138e (diff)
downloadrust-7385f2177f8e3b66ec8f506ed8ec9689460a9b85.tar.gz
rust-7385f2177f8e3b66ec8f506ed8ec9689460a9b85.zip
Fixup: eval_usize needs param env
-rw-r--r--src/librustc_mir/hair/pattern/_match.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/librustc_mir/hair/pattern/_match.rs b/src/librustc_mir/hair/pattern/_match.rs
index 8da4d737cc5..8a3d904e775 100644
--- a/src/librustc_mir/hair/pattern/_match.rs
+++ b/src/librustc_mir/hair/pattern/_match.rs
@@ -228,7 +228,7 @@ impl LiteralExpander<'tcx> {
                 ConstValue::Slice {
                     data: self.tcx.alloc_map.lock().unwrap_memory(p.alloc_id),
                     start: p.offset.bytes().try_into().unwrap(),
-                    end: n.eval_usize(self.tcx, ty::ParamEnv::reveal_all()).try_into().unwrap(),
+                    end: n.eval_usize(self.tcx, ty::ParamEnv::empty()).try_into().unwrap(),
                 }
             },
             // fat pointers stay the same