Commit Graph

7 Commits

Author SHA1 Message Date
bors
d8da513668 Auto merge of #106916 - lukas-code:overlapping-substs, r=estebank
Remove overlapping parts of multipart suggestions

This PR adds a debug assertion that the parts of a single substitution cannot overlap, fixes a overlapping substitution from the testsuite, and fixes https://github.com/rust-lang/rust/issues/106870.

Note that a single suggestion can still have multiple overlapping substitutions / possible edits, we just don't suggest overlapping replacements in a single edit anymore.

I've also included a fix for an unrelated bug where rustfix for `explicit_outlives_requirements` would produce multiple trailing commas for a where clause.
2023-01-28 10:00:56 +00:00
Michael Howell
e237690a28 diagnostics: add }; only if { was added too 2023-01-20 14:53:33 -07:00
Michael Howell
e9d8d238ef diagnostics: suggest changing s@self::{macro}@::macro for exported
Fixes #99695
2023-01-20 14:52:24 -07:00
Lukas Markeffsky
31443c63b5 preserve delim spans during macro_rules! expansion if able 2023-01-20 20:16:37 +01:00
Michael Goulet
21725774a2 note -> help 2023-01-17 03:09:49 +00:00
Michael Goulet
716ea5f19c Fix use suggestion span 2023-01-17 03:06:38 +00:00
Albert Larsan
cf2dff2b1e
Move /src/test to /tests 2023-01-11 09:32:08 +00:00