Skip to content

Commit

Permalink
Mark extern_mod_stmt_cnum as eval_always
Browse files Browse the repository at this point in the history
This query reads from global untracked state, so it always needs to be
evaluated.
  • Loading branch information
Aaron1011 committed Mar 15, 2021
1 parent 7a7bbdb commit e70d47b
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions compiler/rustc_middle/src/query/mod.rs
Expand Up @@ -1278,6 +1278,8 @@ rustc_queries! {
desc { |tcx| "collecting child items of `{}`", tcx.def_path_str(def_id) }
}
query extern_mod_stmt_cnum(def_id: LocalDefId) -> Option<CrateNum> {
// This depends on untracked global state (`tcx.extern_crate_map`)
eval_always
desc { |tcx| "computing crate imported by `{}`", tcx.def_path_str(def_id.to_def_id()) }
}

Expand Down

0 comments on commit e70d47b

Please sign in to comment.