From ebf0fa8eda4490d7435c173037eeb96366171947 Mon Sep 17 00:00:00 2001 From: Jieyou Xu Date: Sun, 7 Dec 2025 23:37:37 +0800 Subject: [PATCH] Fix broken test annotations for `tests/source/issue-6202/long_pat.rs` 1. The test annotations have the wrong syntax. 2. The test is missing a Rust language Edition (>= 2024) for if-let chains. Detected in a subtree sync attempt. --- tests/source/issue-6202/long_pat.rs | 9 +++++---- tests/target/issue-6202/long_pat.rs | 7 ++++--- 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/tests/source/issue-6202/long_pat.rs b/tests/source/issue-6202/long_pat.rs index a7f47f32cb2..4444a4a78cb 100644 --- a/tests/source/issue-6202/long_pat.rs +++ b/tests/source/issue-6202/long_pat.rs @@ -1,6 +1,7 @@ -// max_width = 120 -// error_on_line_overflow = true -// style_edition = "2027" +// rustfmt-max_width: 120 +// rustfmt-error_on_line_overflow: true +// rustfmt-style_edition: 2027 +// rustfmt-edition: 2024 impl EarlyLintPass for NeedlessContinue { fn check_expr(&mut self, cx: &EarlyContext<'_>, expr: &Expr) { @@ -11,4 +12,4 @@ impl EarlyLintPass for NeedlessContinue { check_final_block_stmt(cx, body, label, expr.span.ctxt()); } } -} \ No newline at end of file +} diff --git a/tests/target/issue-6202/long_pat.rs b/tests/target/issue-6202/long_pat.rs index fef118a9da2..1d2282626a2 100644 --- a/tests/target/issue-6202/long_pat.rs +++ b/tests/target/issue-6202/long_pat.rs @@ -1,6 +1,7 @@ -// max_width = 120 -// error_on_line_overflow = true -// style_edition = "2027" +// rustfmt-max_width: 120 +// rustfmt-error_on_line_overflow: true +// rustfmt-style_edition: 2027 +// rustfmt-edition: 2024 impl EarlyLintPass for NeedlessContinue { fn check_expr(&mut self, cx: &EarlyContext<'_>, expr: &Expr) {