Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit f08c43a

Browse files
committedJul 14, 2024
Suppress some fallout from gen in synstructure
1 parent dc20733 commit f08c43a

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed
 

‎compiler/rustc_macros/src/diagnostics/diagnostic.rs

+4
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,8 @@ impl<'a> DiagnosticDerive<'a> {
7171
});
7272

7373
// A lifetime of `'a` causes conflicts, but `_sess` is fine.
74+
// FIXME(edition_2024): Fix the `keyword_idents_2024` lint to not trigger here?
75+
#[allow(keyword_idents_2024)]
7476
let mut imp = structure.gen_impl(quote! {
7577
gen impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for @Self
7678
where G: rustc_errors::EmissionGuarantee
@@ -148,6 +150,8 @@ impl<'a> LintDiagnosticDerive<'a> {
148150
}
149151
});
150152

153+
// FIXME(edition_2024): Fix the `keyword_idents_2024` lint to not trigger here?
154+
#[allow(keyword_idents_2024)]
151155
let mut imp = structure.gen_impl(quote! {
152156
gen impl<'__a> rustc_errors::LintDiagnostic<'__a, ()> for @Self {
153157
#[track_caller]

‎compiler/rustc_macros/src/diagnostics/subdiagnostic.rs

+4
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,9 @@ impl SubdiagnosticDerive {
8686

8787
let diag = &self.diag;
8888
let f = &self.f;
89+
90+
// FIXME(edition_2024): Fix the `keyword_idents_2024` lint to not trigger here?
91+
#[allow(keyword_idents_2024)]
8992
let ret = structure.gen_impl(quote! {
9093
gen impl rustc_errors::Subdiagnostic for @Self {
9194
fn add_to_diag_with<__G, __F>(
@@ -100,6 +103,7 @@ impl SubdiagnosticDerive {
100103
}
101104
}
102105
});
106+
103107
ret
104108
}
105109
}

0 commit comments

Comments
 (0)
Failed to load comments.