@@ -6,7 +6,7 @@ use crate::infer::error_reporting::nice_region_error::NiceRegionError;
66use crate :: infer:: lexical_region_resolve:: RegionResolutionError ;
77use crate :: infer:: { Subtype , ValuePairs } ;
88use crate :: traits:: ObligationCauseCode :: CompareImplMethodObligation ;
9- use rustc_data_structures:: fx:: FxHashSet ;
9+ use rustc_data_structures:: fx:: FxIndexSet ;
1010use rustc_errors:: ErrorReported ;
1111use rustc_middle:: ty:: error:: ExpectedFound ;
1212use rustc_middle:: ty:: fold:: TypeFoldable ;
@@ -70,7 +70,7 @@ impl<'a, 'tcx> NiceRegionError<'a, 'tcx> {
7070 // Because this is confusing as hell the first time you see it, we give a short message
7171 // explaining the situation and proposing constraining the type param with a named lifetime
7272 // so that the `impl` will have one to tie them together.
73- struct AssocTypeFinder ( FxHashSet < ty:: ParamTy > ) ;
73+ struct AssocTypeFinder ( FxIndexSet < ty:: ParamTy > ) ;
7474 impl < ' tcx > ty:: fold:: TypeVisitor < ' tcx > for AssocTypeFinder {
7575 fn visit_ty ( & mut self , ty : Ty < ' tcx > ) -> bool {
7676 debug ! ( "assoc type finder ty {:?} {:?}" , ty, ty. kind) ;
@@ -80,7 +80,7 @@ impl<'a, 'tcx> NiceRegionError<'a, 'tcx> {
8080 ty. super_visit_with ( self )
8181 }
8282 }
83- let mut visitor = AssocTypeFinder ( FxHashSet :: default ( ) ) ;
83+ let mut visitor = AssocTypeFinder ( FxIndexSet :: default ( ) ) ;
8484 trait_fn_sig. output ( ) . visit_with ( & mut visitor) ;
8585 if let Some ( id) = tcx. hir ( ) . as_local_hir_id ( trait_def_id) {
8686 let parent_id = tcx. hir ( ) . get_parent_item ( id) ;
0 commit comments