about summary refs log tree commit diff
path: root/compiler/rustc_errors/src
diff options
context:
space:
mode:
authorOli Scherer <git-spam-no-reply9815368754983@oli-obk.de>2023-09-18 15:30:07 +0000
committerOli Scherer <git-spam-no-reply9815368754983@oli-obk.de>2023-09-21 09:00:22 +0000
commit9c762b58ba9f46e806f7e07b80ef59b45de87471 (patch)
tree8e23c38a45fc374a378ea01e411e852924479eff /compiler/rustc_errors/src
parent44e199bf300a79df302a5b068dba0c39d9a12c0f (diff)
downloadrust-9c762b58ba9f46e806f7e07b80ef59b45de87471.tar.gz
rust-9c762b58ba9f46e806f7e07b80ef59b45de87471.zip
Prevent promotion of const fn calls in inline consts
Diffstat (limited to 'compiler/rustc_errors/src')
-rw-r--r--compiler/rustc_errors/src/diagnostic_impls.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/rustc_errors/src/diagnostic_impls.rs b/compiler/rustc_errors/src/diagnostic_impls.rs
index a170e3a8943..4f77f09b26e 100644
--- a/compiler/rustc_errors/src/diagnostic_impls.rs
+++ b/compiler/rustc_errors/src/diagnostic_impls.rs
@@ -161,7 +161,7 @@ impl IntoDiagnosticArg for hir::ConstContext {
         DiagnosticArgValue::Str(Cow::Borrowed(match self {
             hir::ConstContext::ConstFn => "const_fn",
             hir::ConstContext::Static(_) => "static",
-            hir::ConstContext::Const => "const",
+            hir::ConstContext::Const { .. } => "const",
         }))
     }
 }