1
Fork 0

Remove local testing env var

This commit is contained in:
Aman Arora 2020-11-05 15:36:27 -05:00
parent be77402ee3
commit abc40040be

View file

@ -44,8 +44,6 @@ use rustc_middle::ty::{self, Ty, TyCtxt, UpvarSubsts};
use rustc_span::sym; use rustc_span::sym;
use rustc_span::{Span, Symbol}; use rustc_span::{Span, Symbol};
use std::env;
/// Describe the relationship between the paths of two places /// Describe the relationship between the paths of two places
/// eg: /// eg:
/// - foo is ancestor of foo.bar.baz /// - foo is ancestor of foo.bar.baz
@ -127,8 +125,7 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
let local_def_id = closure_def_id.expect_local(); let local_def_id = closure_def_id.expect_local();
let mut capture_information = FxIndexMap::<Place<'tcx>, ty::CaptureInfo<'tcx>>::default(); let mut capture_information = FxIndexMap::<Place<'tcx>, ty::CaptureInfo<'tcx>>::default();
if self.tcx.features().capture_disjoint_fields || matches!(env::var("SG_NEW"), Ok(_)) { if !self.tcx.features().capture_disjoint_fields {
} else {
if let Some(upvars) = self.tcx.upvars_mentioned(closure_def_id) { if let Some(upvars) = self.tcx.upvars_mentioned(closure_def_id) {
for (&var_hir_id, _) in upvars.iter() { for (&var_hir_id, _) in upvars.iter() {
let place = self.place_for_root_variable(local_def_id, var_hir_id); let place = self.place_for_root_variable(local_def_id, var_hir_id);