mirror of
https://github.com/rust-lang/rust.git
synced 2026-06-01 14:10:03 +03:00
Rustup to rustc 1.17.0-nightly (824c9ebbd 2017-03-12)
This commit is contained in:
+2
-2
@@ -137,9 +137,9 @@ pub(super) fn eval_lvalue(&mut self, mir_lvalue: &mir::Lvalue<'tcx>) -> EvalResu
|
||||
Local(mir::RETURN_POINTER) => self.frame().return_lvalue,
|
||||
Local(local) => Lvalue::Local { frame: self.stack.len() - 1, local, field: None },
|
||||
|
||||
Static(def_id) => {
|
||||
Static(ref statik) => {
|
||||
let substs = self.tcx.intern_substs(&[]);
|
||||
Lvalue::Global(GlobalId { def_id, substs, promoted: None })
|
||||
Lvalue::Global(GlobalId { def_id: statik.def_id, substs, promoted: None })
|
||||
}
|
||||
|
||||
Projection(ref proj) => return self.eval_lvalue_projection(proj),
|
||||
|
||||
+2
-1
@@ -242,7 +242,8 @@ fn visit_lvalue(
|
||||
location: mir::Location
|
||||
) {
|
||||
self.super_lvalue(lvalue, context, location);
|
||||
if let mir::Lvalue::Static(def_id) = *lvalue {
|
||||
if let mir::Lvalue::Static(ref statik) = *lvalue {
|
||||
let def_id = statik.def_id;
|
||||
let substs = self.ecx.tcx.intern_substs(&[]);
|
||||
let span = self.span;
|
||||
if let Some(node_item) = self.ecx.tcx.hir.get_if_local(def_id) {
|
||||
|
||||
Reference in New Issue
Block a user