Skip to content
/ rust Public
forked from rust-lang/rust

Commit 0a6b60b

Browse files
authored
Rollup merge of rust-lang#121913 - Zoxc:query-fix, r=compiler-errors
Don't panic when waiting on poisoned queries This fixes a bug introduced in rust-lang#119086.
2 parents 1938ec0 + dd0004a commit 0a6b60b

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

compiler/rustc_query_system/src/query/plumbing.rs

+2-3
Original file line numberDiff line numberDiff line change
@@ -285,9 +285,8 @@ where
285285
let lock = query.query_state(qcx).active.get_shard_by_value(&key).lock();
286286

287287
match lock.get(&key) {
288-
Some(QueryResult::Poisoned) => {
289-
panic!("query '{}' not cached due to poisoning", query.name())
290-
}
288+
// The query we waited on panicked. Continue unwinding here.
289+
Some(QueryResult::Poisoned) => FatalError.raise(),
291290
_ => panic!(
292291
"query '{}' result must be in the cache or the query must be poisoned after a wait",
293292
query.name()

0 commit comments

Comments
 (0)