about summary refs log tree commit diff
diff options
context:
space:
mode:
authorDouglas Campos <qmx@qmx.me>2017-09-07 22:22:08 -0400
committerDouglas Campos <qmx@qmx.me>2017-09-13 23:00:17 -0400
commitd3bbce79d0c0b3b4525f65e3bc75a8fa2863634a (patch)
tree03fc7aa515a34e486ab602bf835f2157b9cf0f28
parent94211416bcde4d1049f241b6c95594e28c8865e6 (diff)
downloadrust-d3bbce79d0c0b3b4525f65e3bc75a8fa2863634a.tar.gz
rust-d3bbce79d0c0b3b4525f65e3bc75a8fa2863634a.zip
bring TyCtxt into scope
-rw-r--r--src/librustc/ty/instance.rs8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/librustc/ty/instance.rs b/src/librustc/ty/instance.rs
index 7d543f689c2..d9c6843fad7 100644
--- a/src/librustc/ty/instance.rs
+++ b/src/librustc/ty/instance.rs
@@ -9,7 +9,7 @@
 // except according to those terms.
 
 use hir::def_id::DefId;
-use ty::{self, Ty, TypeFoldable, Substs};
+use ty::{self, Ty, TypeFoldable, Substs, TyCtxt};
 use util::ppaux;
 
 use std::fmt;
@@ -57,12 +57,12 @@ impl<'tcx> InstanceDef<'tcx> {
     }
 
     #[inline]
-    pub fn def_ty<'a>(&self, tcx: ty::TyCtxt<'a, 'tcx, 'tcx>) -> Ty<'tcx> {
+    pub fn def_ty<'a>(&self, tcx: TyCtxt<'a, 'tcx, 'tcx>) -> Ty<'tcx> {
         tcx.type_of(self.def_id())
     }
 
     #[inline]
-    pub fn attrs<'a>(&self, tcx: ty::TyCtxt<'a, 'tcx, 'tcx>) -> ty::Attributes<'tcx> {
+    pub fn attrs<'a>(&self, tcx: TyCtxt<'a, 'tcx, 'tcx>) -> ty::Attributes<'tcx> {
         tcx.get_attrs(self.def_id())
     }
 }
@@ -103,7 +103,7 @@ impl<'a, 'b, 'tcx> Instance<'tcx> {
         Instance { def: InstanceDef::Item(def_id), substs: substs }
     }
 
-    pub fn mono(tcx: ty::TyCtxt<'a, 'tcx, 'b>, def_id: DefId) -> Instance<'tcx> {
+    pub fn mono(tcx: TyCtxt<'a, 'tcx, 'b>, def_id: DefId) -> Instance<'tcx> {
         Instance::new(def_id, tcx.global_tcx().empty_substs_for_def_id(def_id))
     }