Skip to content

Commit c1436c3

Browse files
committed
Handle eval_always queries in force()
Part of #45238
1 parent 9d72fc6 commit c1436c3

File tree

1 file changed

+11
-4
lines changed

1 file changed

+11
-4
lines changed

src/librustc/ty/maps/plumbing.rs

+11-4
Original file line numberDiff line numberDiff line change
@@ -433,10 +433,17 @@ macro_rules! define_maps {
433433
profq_msg!(tcx, ProfileQueriesMsg::ProviderBegin);
434434
let res = tcx.cycle_check(span, Query::$name(key), || {
435435
tcx.sess.diagnostic().track_diagnostics(|| {
436-
tcx.dep_graph.with_task(dep_node,
437-
tcx,
438-
key,
439-
Self::compute_result)
436+
if dep_node.kind.is_eval_always() {
437+
tcx.dep_graph.with_eval_always_task(dep_node,
438+
tcx,
439+
key,
440+
Self::compute_result)
441+
} else {
442+
tcx.dep_graph.with_task(dep_node,
443+
tcx,
444+
key,
445+
Self::compute_result)
446+
}
440447
})
441448
})?;
442449
profq_msg!(tcx, ProfileQueriesMsg::ProviderEnd);

0 commit comments

Comments
 (0)