File tree Expand file tree Collapse file tree 2 files changed +13
-11
lines changed Expand file tree Collapse file tree 2 files changed +13
-11
lines changed Original file line number Diff line number Diff line change @@ -1808,7 +1808,7 @@ impl Type {
18081808 . push ( self . ty . clone ( ) )
18091809 . fill ( args. iter ( ) . map ( |t| t. ty . clone ( ) ) )
18101810 . build ( ) ;
1811- let goal = Canonical :: new (
1811+ let goal = hir_ty :: make_canonical (
18121812 InEnvironment :: new (
18131813 self . env . env . clone ( ) ,
18141814 AliasEq {
Original file line number Diff line number Diff line change @@ -107,16 +107,18 @@ pub fn make_only_type_binders<T>(num_vars: usize, value: T) -> Binders<T> {
107107 )
108108}
109109
110- impl < T > Canonical < T > {
111- pub fn new ( value : T , kinds : impl IntoIterator < Item = TyVariableKind > ) -> Self {
112- let kinds = kinds. into_iter ( ) . map ( |tk| {
113- chalk_ir:: CanonicalVarKind :: new (
114- chalk_ir:: VariableKind :: Ty ( tk) ,
115- chalk_ir:: UniverseIndex :: ROOT ,
116- )
117- } ) ;
118- Self { value, binders : chalk_ir:: CanonicalVarKinds :: from_iter ( & Interner , kinds) }
119- }
110+ // FIXME: get rid of this
111+ pub fn make_canonical < T > (
112+ value : T ,
113+ kinds : impl IntoIterator < Item = TyVariableKind > ,
114+ ) -> Canonical < T > {
115+ let kinds = kinds. into_iter ( ) . map ( |tk| {
116+ chalk_ir:: CanonicalVarKind :: new (
117+ chalk_ir:: VariableKind :: Ty ( tk) ,
118+ chalk_ir:: UniverseIndex :: ROOT ,
119+ )
120+ } ) ;
121+ Canonical { value, binders : chalk_ir:: CanonicalVarKinds :: from_iter ( & Interner , kinds) }
120122}
121123
122124/// A function signature as seen by type inference: Several parameter types and
You can’t perform that action at this time.
0 commit comments