File tree Expand file tree Collapse file tree 2 files changed +22
-13
lines changed
Expand file tree Collapse file tree 2 files changed +22
-13
lines changed Original file line number Diff line number Diff line change @@ -63,6 +63,7 @@ normalizations! {
6363 UnindentMultilineNote ,
6464 DependencyVersion ,
6565 HeadingNote ,
66+ UnindentSuggestion ,
6667 // New normalization steps are to be inserted here at the end so that any
6768 // snapshots saved before your normalization change remain passing.
6869}
@@ -669,6 +670,14 @@ fn indented_line_kind(
669670 if spaces > 0
670671 && ( rest == "|"
671672 || rest. starts_with ( "| " )
673+ || normalization >= UnindentSuggestion
674+ && digits > 0
675+ && ( rest == "~"
676+ || rest. starts_with ( "~ " )
677+ || rest == "+"
678+ || rest. starts_with ( "+ " )
679+ || rest == "-"
680+ || rest. starts_with ( "- " ) )
672681 || digits == 0
673682 && ( rest. starts_with ( "--> " ) || rest. starts_with ( "::: " ) || rest. starts_with ( "= " ) ) )
674683 {
Original file line number Diff line number Diff line change @@ -20,21 +20,21 @@ help: ensure that all possible cases are being handled by adding a match arm wit
2020 |
2121" "
2222error[E0004]: non-exhaustive patterns: `MyPhantom::__Phantom(_)` not covered
23- --> src/main.rs:9:11
24- |
25- 9 | match phantom {
26- | ^^^^^^^ pattern `MyPhantom::__Phantom(_)` not covered
27- |
23+ --> src/main.rs:9:11
24+ |
25+ 9 | match phantom {
26+ | ^^^^^^^ pattern `MyPhantom::__Phantom(_)` not covered
27+ |
2828note: `MyPhantom<u8>` defined here
29- --> src/main.rs:4:8
30- |
31- 3 | #[phantom]
32- | ---------- not covered
33- 4 | struct MyPhantom<T: ?Sized>;
34- | ^^^^^^^^^
35- = note: the matched value is of type `MyPhantom<u8>`
29+ --> src/main.rs:4:8
30+ |
31+ 3 | #[phantom]
32+ | ---------- not covered
33+ 4 | struct MyPhantom<T: ?Sized>;
34+ | ^^^^^^^^^
35+ = note: the matched value is of type `MyPhantom<u8>`
3636help: ensure that all possible cases are being handled by adding a match arm with a wildcard pattern or an explicit pattern as shown
37- |
37+ |
383810 ~ MyPhantom => {},
393911 + MyPhantom::__Phantom(_) => todo!()
4040 |
You can’t perform that action at this time.
0 commit comments