Skip to content

Commit

Permalink
Auto merge of #125448 - matthiaskrgr:rollup-vn6nleh, r=matthiaskrgr
Browse files Browse the repository at this point in the history
Rollup of 8 pull requests

Successful merges:

 - #124297 (Allow coercing functions whose signature differs in opaque types in their defining scope into a shared function pointer type)
 - #124516 (Allow monomorphization time const eval failures if the cause is a type layout issue)
 - #124976 (rustc: Use `tcx.used_crates(())` more)
 - #125210 (Cleanup: Fix up some diagnostics)
 - #125409 (Rename `FrameworkOnlyWindows` to `RawDylibOnlyWindows`)
 - #125416 (Use correct param-env in `MissingCopyImplementations`)
 - #125421 (Rewrite `core-no-oom-handling`, `issue-24445` and `issue-38237` `run-make` tests to new `rmake.rs` format)
 - #125438 (Remove unneeded string conversion)

r? `@ghost`
`@rustbot` modify labels: rollup
  • Loading branch information
bors committed May 23, 2024
2 parents bd465c6 + e2ca1c3 commit 6e83f02
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/helpers.rs
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ fn try_resolve_did(tcx: TyCtxt<'_>, path: &[&str], namespace: Option<Namespace>)
// the one in the sysroot and the one locally built by `cargo test`.)
// FIXME: can we prefer the one from the sysroot?
'crates: for krate in
tcx.crates(()).iter().filter(|&&krate| tcx.crate_name(krate).as_str() == crate_name)
tcx.used_crates(()).iter().filter(|&&krate| tcx.crate_name(krate).as_str() == crate_name)
{
let mut cur_item = DefId { krate: *krate, index: CRATE_DEF_INDEX };
// Go over the modules.
Expand Down Expand Up @@ -1365,7 +1365,7 @@ pub fn get_local_crates(tcx: TyCtxt<'_>) -> Vec<CrateNum> {
.map(|crates| crates.split(',').map(|krate| krate.to_string()).collect::<Vec<_>>())
.unwrap_or_default();
let mut local_crates = Vec::new();
for &crate_num in tcx.crates(()) {
for &crate_num in tcx.crates_including_speculative(()) {
let name = tcx.crate_name(crate_num);
let name = name.as_str();
if local_crate_names.iter().any(|local_name| local_name == name) {
Expand Down

0 comments on commit 6e83f02

Please sign in to comment.