@@ -19,6 +19,7 @@ use super::{CombinedSnapshot,
19
19
use super :: combine:: CombineFields ;
20
20
use super :: region_inference:: { TaintDirections } ;
21
21
22
+ use std:: collections:: BTreeMap ;
22
23
use ty:: { self , TyCtxt , Binder , TypeFoldable } ;
23
24
use ty:: error:: TypeError ;
24
25
use ty:: relate:: { Relate , RelateResult , TypeRelation } ;
@@ -245,7 +246,7 @@ impl<'a, 'gcx, 'tcx> CombineFields<'a, 'gcx, 'tcx> {
245
246
snapshot : & CombinedSnapshot ,
246
247
debruijn : ty:: DebruijnIndex ,
247
248
new_vars : & [ ty:: RegionVid ] ,
248
- a_map : & FxHashMap < ty:: BoundRegion , ty:: Region < ' tcx > > ,
249
+ a_map : & BTreeMap < ty:: BoundRegion , ty:: Region < ' tcx > > ,
249
250
r0 : ty:: Region < ' tcx > )
250
251
-> ty:: Region < ' tcx > {
251
252
// Regions that pre-dated the LUB computation stay as they are.
@@ -341,7 +342,7 @@ impl<'a, 'gcx, 'tcx> CombineFields<'a, 'gcx, 'tcx> {
341
342
snapshot : & CombinedSnapshot ,
342
343
debruijn : ty:: DebruijnIndex ,
343
344
new_vars : & [ ty:: RegionVid ] ,
344
- a_map : & FxHashMap < ty:: BoundRegion , ty:: Region < ' tcx > > ,
345
+ a_map : & BTreeMap < ty:: BoundRegion , ty:: Region < ' tcx > > ,
345
346
a_vars : & [ ty:: RegionVid ] ,
346
347
b_vars : & [ ty:: RegionVid ] ,
347
348
r0 : ty:: Region < ' tcx > )
@@ -410,7 +411,7 @@ impl<'a, 'gcx, 'tcx> CombineFields<'a, 'gcx, 'tcx> {
410
411
411
412
fn rev_lookup < ' a , ' gcx , ' tcx > ( infcx : & InferCtxt < ' a , ' gcx , ' tcx > ,
412
413
span : Span ,
413
- a_map : & FxHashMap < ty:: BoundRegion , ty:: Region < ' tcx > > ,
414
+ a_map : & BTreeMap < ty:: BoundRegion , ty:: Region < ' tcx > > ,
414
415
r : ty:: Region < ' tcx > ) -> ty:: Region < ' tcx >
415
416
{
416
417
for ( a_br, a_r) in a_map {
@@ -433,7 +434,7 @@ impl<'a, 'gcx, 'tcx> CombineFields<'a, 'gcx, 'tcx> {
433
434
}
434
435
435
436
fn var_ids < ' a , ' gcx , ' tcx > ( fields : & CombineFields < ' a , ' gcx , ' tcx > ,
436
- map : & FxHashMap < ty:: BoundRegion , ty:: Region < ' tcx > > )
437
+ map : & BTreeMap < ty:: BoundRegion , ty:: Region < ' tcx > > )
437
438
-> Vec < ty:: RegionVid > {
438
439
map. iter ( )
439
440
. map ( |( _, & r) | match * r {
0 commit comments