about summary refs log tree commit diff
path: root/src/bootstrap
diff options
context:
space:
mode:
authorMichael Goulet <michael@errs.io>2023-08-22 09:00:49 -0700
committerGitHub <noreply@github.com>2023-08-22 09:00:49 -0700
commite9897c3a7101abd6539dcaa2e87a9588b1c9b0d9 (patch)
tree7b34c5f71c14d81fb6da5398878bd31a6adf51cc /src/bootstrap
parent6c7678d3289c7ccae1f70ddcb1f7327465cbca24 (diff)
parentb1c609e2a6716cb76d2690d86d2d9c255cacbb18 (diff)
Rollup merge of #115011 - compiler-errors:warn-on-elided-assoc-ct-lt, r=cjgillot
Warn on elided lifetimes in associated constants (`ELIDED_LIFETIMES_IN_ASSOCIATED_CONSTANT`)

Elided lifetimes in associated constants (in impls) erroneously resolve to fresh lifetime parameters on the impl since #97313. This is not correct behavior (see #38831).

I originally opened #114716 to fix this, but given the time that has passed, the crater results seem pretty bad: https://github.com/rust-lang/rust/pull/114716#issuecomment-1682091952

This PR alternatively implements a lint against this behavior, and I'm hoping to bump this to deny in a few versions.
Diffstat (limited to 'src/bootstrap')
-rw-r--r--src/bootstrap/tool.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/bootstrap/tool.rs b/src/bootstrap/tool.rs
index e6d27757ac6..07ff3da6b4a 100644
--- a/src/bootstrap/tool.rs
+++ b/src/bootstrap/tool.rs
@@ -601,7 +601,7 @@ pub struct RustAnalyzer {
 }
 
 impl RustAnalyzer {
-    pub const ALLOW_FEATURES: &str =
+    pub const ALLOW_FEATURES: &'static str =
         "proc_macro_internals,proc_macro_diagnostic,proc_macro_span,proc_macro_span_shrink";
 }