|
9 | 9 | // except according to those terms.
|
10 | 10 |
|
11 | 11 | use hir::def_id::DefId;
|
12 |
| -use ty::{self, Ty, TypeFoldable, Substs}; |
| 12 | +use ty::{self, Ty, TypeFoldable, Substs, TyCtxt}; |
13 | 13 | use util::ppaux;
|
14 | 14 |
|
15 | 15 | use std::fmt;
|
@@ -57,12 +57,12 @@ impl<'tcx> InstanceDef<'tcx> {
|
57 | 57 | }
|
58 | 58 |
|
59 | 59 | #[inline]
|
60 |
| - pub fn def_ty<'a>(&self, tcx: ty::TyCtxt<'a, 'tcx, 'tcx>) -> Ty<'tcx> { |
| 60 | + pub fn def_ty<'a>(&self, tcx: TyCtxt<'a, 'tcx, 'tcx>) -> Ty<'tcx> { |
61 | 61 | tcx.type_of(self.def_id())
|
62 | 62 | }
|
63 | 63 |
|
64 | 64 | #[inline]
|
65 |
| - pub fn attrs<'a>(&self, tcx: ty::TyCtxt<'a, 'tcx, 'tcx>) -> ty::Attributes<'tcx> { |
| 65 | + pub fn attrs<'a>(&self, tcx: TyCtxt<'a, 'tcx, 'tcx>) -> ty::Attributes<'tcx> { |
66 | 66 | tcx.get_attrs(self.def_id())
|
67 | 67 | }
|
68 | 68 | }
|
@@ -103,7 +103,7 @@ impl<'a, 'b, 'tcx> Instance<'tcx> {
|
103 | 103 | Instance { def: InstanceDef::Item(def_id), substs: substs }
|
104 | 104 | }
|
105 | 105 |
|
106 |
| - pub fn mono(tcx: ty::TyCtxt<'a, 'tcx, 'b>, def_id: DefId) -> Instance<'tcx> { |
| 106 | + pub fn mono(tcx: TyCtxt<'a, 'tcx, 'b>, def_id: DefId) -> Instance<'tcx> { |
107 | 107 | Instance::new(def_id, tcx.global_tcx().empty_substs_for_def_id(def_id))
|
108 | 108 | }
|
109 | 109 |
|
|
0 commit comments