File tree 1 file changed +15
-0
lines changed
src/librustc_middle/traits
1 file changed +15
-0
lines changed Original file line number Diff line number Diff line change @@ -75,6 +75,7 @@ impl<'tcx> chalk_ir::interner::Interner for RustInterner<'tcx> {
75
75
type InternedQuantifiedWhereClauses = Vec < chalk_ir:: QuantifiedWhereClause < Self > > ;
76
76
type InternedVariableKinds = Vec < chalk_ir:: VariableKind < Self > > ;
77
77
type InternedCanonicalVarKinds = Vec < chalk_ir:: CanonicalVarKind < Self > > ;
78
+ type InternedConstraints = Vec < chalk_ir:: InEnvironment < chalk_ir:: Constraint < Self > > > ;
78
79
type DefId = DefId ;
79
80
type InternedAdtId = & ' tcx AdtDef ;
80
81
type Identifier = ( ) ;
@@ -321,6 +322,20 @@ impl<'tcx> chalk_ir::interner::Interner for RustInterner<'tcx> {
321
322
) -> & ' a [ chalk_ir:: CanonicalVarKind < Self > ] {
322
323
canonical_var_kinds
323
324
}
325
+
326
+ fn intern_constraints < E > (
327
+ & self ,
328
+ data : impl IntoIterator < Item = Result < chalk_ir:: InEnvironment < chalk_ir:: Constraint < Self > > , E > > ,
329
+ ) -> Result < Self :: InternedConstraints , E > {
330
+ data. into_iter ( ) . collect :: < Result < Vec < _ > , _ > > ( )
331
+ }
332
+
333
+ fn constraints_data < ' a > (
334
+ & self ,
335
+ constraints : & ' a Self :: InternedConstraints ,
336
+ ) -> & ' a [ chalk_ir:: InEnvironment < chalk_ir:: Constraint < Self > > ] {
337
+ constraints
338
+ }
324
339
}
325
340
326
341
impl < ' tcx > chalk_ir:: interner:: HasInterner for RustInterner < ' tcx > {
You can’t perform that action at this time.
0 commit comments