File tree Expand file tree Collapse file tree 1 file changed +15
-0
lines changed
src/librustc_middle/traits Expand file tree Collapse file tree 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> {
7575 type InternedQuantifiedWhereClauses = Vec < chalk_ir:: QuantifiedWhereClause < Self > > ;
7676 type InternedVariableKinds = Vec < chalk_ir:: VariableKind < Self > > ;
7777 type InternedCanonicalVarKinds = Vec < chalk_ir:: CanonicalVarKind < Self > > ;
78+ type InternedConstraints = Vec < chalk_ir:: InEnvironment < chalk_ir:: Constraint < Self > > > ;
7879 type DefId = DefId ;
7980 type InternedAdtId = & ' tcx AdtDef ;
8081 type Identifier = ( ) ;
@@ -321,6 +322,20 @@ impl<'tcx> chalk_ir::interner::Interner for RustInterner<'tcx> {
321322 ) -> & ' a [ chalk_ir:: CanonicalVarKind < Self > ] {
322323 canonical_var_kinds
323324 }
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+ }
324339}
325340
326341impl < ' tcx > chalk_ir:: interner:: HasInterner for RustInterner < ' tcx > {
You can’t perform that action at this time.
0 commit comments