Rollup merge of #126882 - estebank:multiline-order, r=WaffleLapkin

Special case when a code line only has multiline span starts

Minimize multline span overlap when there are multiple of them starting on the same line:

```
3 |       X0 Y0 Z0
  |  _____^  -  -
  | | _______|  |
  | || _________|
4 | |||   X1 Y1 Z1
5 | |||   X2 Y2 Z2
  | |||____^__-__- `Z` label
  | ||_____|__|
  | |______|  `Y` is a good letter too
  |        `X` is a good letter
```
This commit is contained in:
Matthias Krüger 2024-06-24 15:06:23 +02:00 committed by GitHub
commit a80ee9159b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 37 additions and 17 deletions

View file

@ -322,9 +322,8 @@ error: foo
--> test.rs:3:3
|
3 | X0 Y0
| ___^__-
| |___|
| ||
| ____^ -
| | ______|
4 | || X1 Y1
5 | || X2 Y2
| ||____^__- `Y` is a good letter too
@ -361,9 +360,8 @@ error: foo
--> test.rs:3:3
|
3 | X0 Y0
| ___^__-
| |___|
| ||
| ____^ -
| | ______|
4 | || Y1 X1
| ||____-__^ `X` is a good letter
| |____|
@ -445,10 +443,9 @@ error: foo
--> test.rs:3:3
|
3 | X0 Y0 Z0
| ___^__-__-
| |___|__|
| ||___|
| |||
| _____^ - -
| | _______| |
| || _________|
4 | ||| X1 Y1 Z1
5 | ||| X2 Y2 Z2
| |||____^__-__- `Z` label