From 76d573b656e4f20c8297fff0704fcf14ad86f9b7 Mon Sep 17 00:00:00 2001 From: Camille GILLOT Date: Thu, 20 Apr 2023 18:56:12 +0000 Subject: [PATCH] Add info for no_hash panic. --- compiler/rustc_query_system/src/query/plumbing.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/compiler/rustc_query_system/src/query/plumbing.rs b/compiler/rustc_query_system/src/query/plumbing.rs index c122c7d722d..bce01debc53 100644 --- a/compiler/rustc_query_system/src/query/plumbing.rs +++ b/compiler/rustc_query_system/src/query/plumbing.rs @@ -412,7 +412,9 @@ where if let Some((cached_result, _)) = cache.lookup(&key) { let Some(hasher) = query.hash_result() else { panic!( - "fed query later has its value computed. The already cached value: {}", + "no_hash fed query later has its value computed.\n\ + Remove `no_hash` modifier to allow recomputation.\n\ + The already cached value: {}", (query.format_value())(&cached_result) ); };