about summary refs log tree commit diff
path: root/src/librustc/metadata
diff options
context:
space:
mode:
authorAriel Ben-Yehuda <ariel.byd@gmail.com>2015-09-13 18:22:05 +0300
committerAriel Ben-Yehuda <ariel.byd@gmail.com>2015-09-13 20:59:40 +0300
commit8478acf695ccd3bf4abe8c65f153dfbc99f3d28c (patch)
treed575d0e69148a2b00e087c73f9932ac9824d08b9 /src/librustc/metadata
parentcfd76b364cd01695517467299618ef63f1c0cc07 (diff)
sort the existential bounds list in tydecode
The sort key is a (DefId, Name), which is *not* stable between
runs, so we must re-sort when loading.

Fixes #24063
Fixes #25467
Fixes #27222
Fixes #28377
Diffstat (limited to 'src/librustc/metadata')
-rw-r--r--src/librustc/metadata/tydecode.rs5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/librustc/metadata/tydecode.rs b/src/librustc/metadata/tydecode.rs
index 0c802356af1..e58267f9291 100644
--- a/src/librustc/metadata/tydecode.rs
+++ b/src/librustc/metadata/tydecode.rs
@@ -680,9 +680,8 @@ impl<'a,'tcx> TyDecoder<'a,'tcx> {
             }
         }
 
-        return ty::ExistentialBounds { region_bound: region_bound,
-                                       builtin_bounds: builtin_bounds,
-                                       projection_bounds: projection_bounds };
+        ty::ExistentialBounds::new(
+            region_bound, builtin_bounds, projection_bounds)
     }
 
     fn parse_builtin_bounds(&mut self) -> ty::BuiltinBounds {