Commit graph

14 commits

Author SHA1 Message Date
Matthias Krüger
e9c4e291c4
Rollup merge of #107493 - clubby789:range-fat-arrow-followup, r=estebank
Improve diagnostic for missing space in range pattern

Improves the diagnostic in #107425 by turning it into a note explaining the parsing issue.

r? `@compiler-errors`
2023-02-02 17:14:05 +01:00
clubby789
4ab75de934 Improve diagnostic for missing space in range pattern 2023-02-02 13:18:12 +00:00
Michael Goulet
9dd5d3e8e4 Recover _ as .. in field pattern 2023-02-02 06:10:02 +00:00
Xiretza
0d0d369915 Make "use latest edition" subdiagnostic translatable 2023-02-01 21:56:28 +01:00
Xiretza
7631b12e3e migrate parser::ty to diagnostic structs 2023-02-01 21:56:27 +01:00
Xiretza
87ef37dbd7 rustc_parse: migrate more to diagnostic structs 2023-02-01 21:50:34 +01:00
clubby789
c5688794e2 Migrate some range parsing diagnostics 2023-01-28 21:57:35 +00:00
Edward Shen
a8b77cfe54
Add suggestion to remove if in let...else block
Adds an additional hint to failures where we encounter an else keyword
while we're parsing an if-let block.

This is likely that the user has accidentally mixed if-let and let...else
together.
2023-01-23 20:33:04 -08:00
bors
d4203eda5f Auto merge of #106537 - fmease:recover-where-clause-before-tuple-struct-body, r=estebank
Recover from where clauses placed before tuple struct bodies

Open to any suggestions regarding the phrasing of the diagnostic.

Fixes #100790.
`@rustbot` label A-diagnostics
r? diagnostics
2023-01-12 02:16:16 +00:00
León Orell Valerian Liehr
70ddde76df
parser: recover from where clauses placed before tuple struct bodies 2023-01-11 17:54:48 +01:00
Esteban Küber
5311938531 Detect struct literal needing parentheses
Fix #82051.
2023-01-11 16:53:21 +00:00
Michael Goulet
aff403cf68 Recover fn keyword as Fn trait in bounds 2022-12-27 06:14:46 +00:00
yukang
b70a869d8f fix #105366, suggest impl in the scenario of typo with fn 2022-12-10 11:01:52 +08:00
mejrs
fe212eca76 Match crate and slug names 2022-11-21 15:24:50 +01:00