Skip to content

Commit 98ec95d

Browse files
committed
---
yaml --- r: 181862 b: refs/heads/auto c: 7134ad4 h: refs/heads/master v: v3
1 parent 0ae25c2 commit 98ec95d

File tree

7 files changed

+5
-15
lines changed

7 files changed

+5
-15
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ refs/tags/release-0.3: b5f0d0f648d9a6153664837026ba1be43d3e2503
1010
refs/tags/release-0.3.1: 495bae036dfe5ec6ceafd3312b4dca48741e845b
1111
refs/tags/release-0.4: e828ea2080499553b97dfe33b3f4d472b4562ad7
1212
refs/tags/release-0.5: 7e3bcfbf21278251ee936ad53e92e9b719702d73
13-
refs/heads/auto: e84a719e375ac48c6792d0495fb3302879bf7916
13+
refs/heads/auto: 7134ad4d6402e4a1d84a7ebfa417170c107642cb
1414
refs/heads/servo: af82457af293e2a842ba6b7759b70288da276167
1515
refs/tags/release-0.6: b4ebcfa1812664df5e142f0134a5faea3918544c
1616
refs/tags/0.1: b19db808c2793fe2976759b85a355c3ad8c8b336

branches/auto/src/librustc/middle/mem_categorization.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -281,7 +281,6 @@ pub type McResult<T> = Result<T, ()>;
281281
/// know that no errors have occurred, so we simply consult the tcx and we
282282
/// can be sure that only `Ok` results will occur.
283283
pub trait Typer<'tcx> : ty::ClosureTyper<'tcx> {
284-
fn tcx<'a>(&'a self) -> &'a ty::ctxt<'tcx>;
285284
fn node_ty(&self, id: ast::NodeId) -> McResult<Ty<'tcx>>;
286285
fn expr_ty_adjusted(&self, expr: &ast::Expr) -> McResult<Ty<'tcx>>;
287286
fn type_moves_by_default(&self, span: Span, ty: Ty<'tcx>) -> bool;

branches/auto/src/librustc/middle/traits/fulfill.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@
99
// except according to those terms.
1010

1111
use middle::infer::{InferCtxt};
12-
use middle::mem_categorization::Typer;
1312
use middle::ty::{self, RegionEscape, Ty};
1413
use std::collections::HashSet;
1514
use std::collections::hash_map::Entry::{Occupied, Vacant};

branches/auto/src/librustc/middle/traits/select.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,6 @@ use super::object_safety;
3232
use super::{util};
3333

3434
use middle::fast_reject;
35-
use middle::mem_categorization::Typer;
3635
use middle::subst::{Subst, Substs, TypeSpace, VecPerParamSpace};
3736
use middle::ty::{self, RegionEscape, ToPolyTraitRef, Ty};
3837
use middle::infer;

branches/auto/src/librustc/middle/ty.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2337,6 +2337,10 @@ impl ClosureKind {
23372337
}
23382338

23392339
pub trait ClosureTyper<'tcx> {
2340+
fn tcx(&self) -> &ty::ctxt<'tcx> {
2341+
self.param_env().tcx
2342+
}
2343+
23402344
fn param_env<'a>(&'a self) -> &'a ty::ParameterEnvironment<'a, 'tcx>;
23412345

23422346
/// Is this a `Fn`, `FnMut` or `FnOnce` closure? During typeck,
@@ -6463,10 +6467,6 @@ impl<'tcx> ctxt<'tcx> {
64636467
}
64646468

64656469
impl<'a,'tcx> mc::Typer<'tcx> for ParameterEnvironment<'a,'tcx> {
6466-
fn tcx(&self) -> &ty::ctxt<'tcx> {
6467-
self.tcx
6468-
}
6469-
64706470
fn node_ty(&self, id: ast::NodeId) -> mc::McResult<Ty<'tcx>> {
64716471
Ok(ty::node_id_to_type(self.tcx, id))
64726472
}

branches/auto/src/librustc_trans/trans/common.rs

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -637,10 +637,6 @@ impl<'blk, 'tcx> BlockS<'blk, 'tcx> {
637637
}
638638

639639
impl<'blk, 'tcx> mc::Typer<'tcx> for BlockS<'blk, 'tcx> {
640-
fn tcx<'a>(&'a self) -> &'a ty::ctxt<'tcx> {
641-
self.tcx()
642-
}
643-
644640
fn node_ty(&self, id: ast::NodeId) -> mc::McResult<Ty<'tcx>> {
645641
Ok(node_id_type(self, id))
646642
}

branches/auto/src/librustc_typeck/check/mod.rs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -309,9 +309,6 @@ pub struct FnCtxt<'a, 'tcx: 'a> {
309309
}
310310

311311
impl<'a, 'tcx> mc::Typer<'tcx> for FnCtxt<'a, 'tcx> {
312-
fn tcx(&self) -> &ty::ctxt<'tcx> {
313-
self.ccx.tcx
314-
}
315312
fn node_ty(&self, id: ast::NodeId) -> McResult<Ty<'tcx>> {
316313
let ty = self.node_ty(id);
317314
self.resolve_type_vars_or_error(&ty)

0 commit comments

Comments
 (0)