@@ -17,7 +17,6 @@ mod chalk_cast;
17
17
mod chalk_ext;
18
18
mod builder;
19
19
mod walk;
20
- mod types;
21
20
22
21
pub mod display;
23
22
pub mod db;
@@ -48,7 +47,6 @@ pub use lower::{
48
47
TyDefId , TyLoweringContext , ValueTyDefId ,
49
48
} ;
50
49
pub use traits:: { chalk:: Interner , TraitEnvironment } ;
51
- pub use types:: * ;
52
50
pub use walk:: TypeWalk ;
53
51
54
52
pub use chalk_ir:: {
@@ -65,6 +63,21 @@ pub type PlaceholderIndex = chalk_ir::PlaceholderIndex;
65
63
pub type VariableKind = chalk_ir:: VariableKind < Interner > ;
66
64
pub type VariableKinds = chalk_ir:: VariableKinds < Interner > ;
67
65
pub type CanonicalVarKinds = chalk_ir:: CanonicalVarKinds < Interner > ;
66
+ pub type Binders < T > = chalk_ir:: Binders < T > ;
67
+ pub type Substitution = chalk_ir:: Substitution < Interner > ;
68
+ pub type GenericArg = chalk_ir:: GenericArg < Interner > ;
69
+ pub type GenericArgData = chalk_ir:: GenericArgData < Interner > ;
70
+
71
+ pub type Ty = chalk_ir:: Ty < Interner > ;
72
+ pub type TyKind = chalk_ir:: TyKind < Interner > ;
73
+ pub type DynTy = chalk_ir:: DynTy < Interner > ;
74
+ pub type FnPointer = chalk_ir:: FnPointer < Interner > ;
75
+ // pub type FnSubst = chalk_ir::FnSubst<Interner>;
76
+ pub use chalk_ir:: FnSubst ;
77
+ pub type ProjectionTy = chalk_ir:: ProjectionTy < Interner > ;
78
+ pub type AliasTy = chalk_ir:: AliasTy < Interner > ;
79
+ pub type OpaqueTy = chalk_ir:: OpaqueTy < Interner > ;
80
+ pub type InferenceVar = chalk_ir:: InferenceVar ;
68
81
69
82
pub type Lifetime = chalk_ir:: Lifetime < Interner > ;
70
83
pub type LifetimeData = chalk_ir:: LifetimeData < Interner > ;
@@ -79,6 +92,14 @@ pub type ChalkTraitId = chalk_ir::TraitId<Interner>;
79
92
80
93
pub type FnSig = chalk_ir:: FnSig < Interner > ;
81
94
95
+ pub type InEnvironment < T > = chalk_ir:: InEnvironment < T > ;
96
+ pub type DomainGoal = chalk_ir:: DomainGoal < Interner > ;
97
+ pub type AliasEq = chalk_ir:: AliasEq < Interner > ;
98
+ pub type Solution = chalk_solve:: Solution < Interner > ;
99
+ pub type ConstrainedSubst = chalk_ir:: ConstrainedSubst < Interner > ;
100
+ pub type Guidance = chalk_solve:: Guidance < Interner > ;
101
+ pub type WhereClause = chalk_ir:: WhereClause < Interner > ;
102
+
82
103
// FIXME: get rid of this
83
104
pub fn subst_prefix ( s : & Substitution , n : usize ) -> Substitution {
84
105
Substitution :: intern ( s. interned ( ) [ ..std:: cmp:: min ( s. len ( & Interner ) , n) ] . into ( ) )
@@ -121,6 +142,14 @@ pub fn make_canonical<T>(
121
142
Canonical { value, binders : chalk_ir:: CanonicalVarKinds :: from_iter ( & Interner , kinds) }
122
143
}
123
144
145
+ pub type TraitRef = chalk_ir:: TraitRef < Interner > ;
146
+
147
+ pub type QuantifiedWhereClause = Binders < WhereClause > ;
148
+
149
+ pub type QuantifiedWhereClauses = chalk_ir:: QuantifiedWhereClauses < Interner > ;
150
+
151
+ pub type Canonical < T > = chalk_ir:: Canonical < T > ;
152
+
124
153
/// A function signature as seen by type inference: Several parameter types and
125
154
/// one return type.
126
155
#[ derive( Clone , PartialEq , Eq , Debug ) ]
@@ -164,8 +193,6 @@ impl CallableSig {
164
193
}
165
194
}
166
195
167
- impl Ty { }
168
-
169
196
#[ derive( Copy , Clone , PartialEq , Eq , Debug , Hash ) ]
170
197
pub enum ImplTraitId {
171
198
ReturnTypeImplTrait ( hir_def:: FunctionId , u16 ) ,
0 commit comments