Skip to content

Commit 36777f1

Browse files
committed
future-compat lint for newly handled cases of #[structural_match].
1 parent 507ee72 commit 36777f1

File tree

2 files changed

+11
-0
lines changed

2 files changed

+11
-0
lines changed

src/librustc/lint/builtin.rs

+6
Original file line numberDiff line numberDiff line change
@@ -346,6 +346,12 @@ declare_lint! {
346346
"outlives requirements can be inferred"
347347
}
348348

349+
declare_lint! {
350+
pub INDIRECT_STRUCTURAL_MATCH,
351+
Warn,
352+
"pattern with const indirectly referencing non-`#[structural_match]` type"
353+
}
354+
349355
/// Some lints that are buffered from `libsyntax`. See `syntax::early_buffered_lints`.
350356
pub mod parser {
351357
declare_lint! {

src/librustc_lint/lib.rs

+5
Original file line numberDiff line numberDiff line change
@@ -427,6 +427,11 @@ pub fn register_builtins(store: &mut lint::LintStore, sess: Option<&Session>) {
427427
id: LintId::of(MUTABLE_BORROW_RESERVATION_CONFLICT),
428428
reference: "issue #59159 <https://github.com/rust-lang/rust/issues/59159>",
429429
edition: None,
430+
},
431+
FutureIncompatibleInfo {
432+
id: LintId::of(INDIRECT_STRUCTURAL_MATCH),
433+
reference: "issue #62411 <https://github.com/rust-lang/rust/issues/62411>",
434+
edition: None,
430435
}
431436
]);
432437

0 commit comments

Comments
 (0)