We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 3978a05 commit 644dcd0Copy full SHA for 644dcd0
compiler/rustc_metadata/src/rmeta/encoder.rs
@@ -1300,7 +1300,7 @@ impl EncodeContext<'a, 'tcx> {
1300
})
1301
.collect::<Vec<_>>();
1302
// Sort everything to ensure a stable order for diagnotics.
1303
- keys_and_jobs.sort_by_key(|&(def_id, _, _)| def_id);
+ keys_and_jobs.sort_by_key(|&(def_id, _, _)| def_id.index());
1304
for (def_id, encode_const, encode_opt) in keys_and_jobs.into_iter() {
1305
debug_assert!(encode_const || encode_opt);
1306
0 commit comments