rust/tests/ui/parser/macro
Jacob Pratt da493c91d6
Rollup merge of #137435 - estebank:match-arm-2, r=compiler-errors
Fix "missing match arm body" suggestion involving `!`

Include the match arm guard in the gated span, so that the suggestion to add a body is correct instead of inserting the body before the guard.

Make the suggestion verbose.

```
error: `match` arm with no body
  --> $DIR/feature-gate-never_patterns.rs:43:9
   |
LL |         Some(_) if false,
   |         ^^^^^^^^^^^^^^^^
   |
help: add a body after the pattern
   |
LL |         Some(_) if false => { todo!() },
   |                          ++++++++++++++
```

r? `@compiler-errors`
2025-02-23 02:44:19 -05:00
..
bad-macro-argument.rs
bad-macro-argument.stderr
issue-33569.rs
issue-33569.stderr Mark missing_fragment_specifier as FutureReleaseErrorReportInDeps 2024-07-24 13:16:46 -04:00
issue-37113.rs Remove NtTy. 2025-02-21 15:49:46 +11:00
issue-37113.stderr Remove NtTy. 2025-02-21 15:49:46 +11:00
issue-37234.rs
issue-37234.stderr
literals-are-validated-before-expansion.rs
literals-are-validated-before-expansion.stderr
macro-doc-comments-1.rs Tweak more warnings. 2024-10-28 14:20:28 +11:00
macro-doc-comments-1.stderr Tweak more warnings. 2024-10-28 14:20:28 +11:00
macro-doc-comments-2.rs Tweak more warnings. 2024-10-28 14:20:28 +11:00
macro-doc-comments-2.stderr Tweak more warnings. 2024-10-28 14:20:28 +11:00
macro-expand-to-field.rs
macro-expand-to-field.stderr
macro-expand-to-match-arm.rs Tweak expand_incomplete_parse warning. 2024-10-28 14:12:45 +11:00
macro-expand-to-match-arm.stderr Fix "missing match arm body" suggestion involving ! 2025-02-22 18:30:14 +00:00
macro-incomplete-parse.rs Tweak expand_incomplete_parse warning. 2024-10-28 14:12:45 +11:00
macro-incomplete-parse.stderr Tweak expand_incomplete_parse warning. 2024-10-28 14:12:45 +11:00
macro-repeat.rs
macro-repeat.stderr Spruce up the diagnostics of some early lints 2024-06-03 07:25:32 +02:00
mbe-bare-trait-object-maybe-trait-bound.rs
mbe-dotdotdot-may-not-begin-a-type.rs Reject CVarArgs in parse_ty_for_where_clause 2024-06-01 20:57:15 +02:00
pub-item-macro.rs
pub-item-macro.stderr Make parse error suggestions verbose and fix spans 2024-07-12 03:02:57 +00:00
statement-boundaries.rs Add parser tests for statement boundary insertion 2024-05-11 15:49:50 -07:00
trait-non-item-macros.rs Tweak expand_incomplete_parse warning. 2024-10-28 14:12:45 +11:00
trait-non-item-macros.stderr Tweak expand_incomplete_parse warning. 2024-10-28 14:12:45 +11:00
trait-object-macro-matcher.rs Remove NtTy. 2025-02-21 15:49:46 +11:00
trait-object-macro-matcher.stderr Remove NtTy. 2025-02-21 15:49:46 +11:00