1
Fork 0

Allow for more efficient sorting when exporting Unord collections.

This commit is contained in:
Michael Woerister 2023-01-18 10:47:31 +01:00
parent c3d2573120
commit 72ee14ce39
7 changed files with 99 additions and 34 deletions

View file

@ -177,7 +177,7 @@ fn exported_symbols_provider_local(
// Can we skip the later sorting?
let mut symbols: Vec<_> = tcx.with_stable_hashing_context(|hcx| {
tcx.reachable_non_generics(LOCAL_CRATE)
.to_sorted(&hcx)
.to_sorted(&hcx, true)
.into_iter()
.map(|(&def_id, &info)| (ExportedSymbol::NonGeneric(def_id), info))
.collect()