rustc_resolve: fix instability in lib.rmeta contents
rust-lang/rust@23032f31c9 accidentally introduced some nondeterminism in the ordering of lib.rmeta files, which we caught in our bazel-based builds only recently due to being further behind than normal. In my testing, this fixes the issue.
This commit is contained in:
parent
75530e9f72
commit
795a6669f8
3 changed files with 4 additions and 1 deletions
|
@ -1,6 +1,7 @@
|
|||
use std::mem;
|
||||
use std::ops::Range;
|
||||
|
||||
use itertools::Itertools;
|
||||
use pulldown_cmark::{
|
||||
BrokenLink, BrokenLinkCallback, CowStr, Event, LinkType, Options, Parser, Tag,
|
||||
};
|
||||
|
@ -454,7 +455,7 @@ fn parse_links<'md>(doc: &'md str) -> Vec<Box<str>> {
|
|||
}
|
||||
}
|
||||
|
||||
for (label, refdef) in event_iter.reference_definitions().iter() {
|
||||
for (label, refdef) in event_iter.reference_definitions().iter().sorted_by_key(|x| x.0) {
|
||||
if !refids.contains(label) {
|
||||
links.push(preprocess_link(&refdef.dest));
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue