Modify primary span label for E0308
The previous output was unintuitive to users.
This commit is contained in:
parent
006ca9b14d
commit
62ba3e70a1
383 changed files with 889 additions and 926 deletions
|
@ -4,7 +4,7 @@ error[E0061]: this enum variant takes 1 argument but 2 arguments were supplied
|
|||
LL | let _: Option<(i32, bool)> = Some(1, 2);
|
||||
| ^^^^ - argument of type `{integer}` unexpected
|
||||
|
|
||||
note: expected tuple, found integer
|
||||
note: expected `(i32, bool)`, found integer
|
||||
--> $DIR/args-instead-of-tuple-errors.rs:6:39
|
||||
|
|
||||
LL | let _: Option<(i32, bool)> = Some(1, 2);
|
||||
|
@ -31,7 +31,7 @@ error[E0061]: this function takes 1 argument but 2 arguments were supplied
|
|||
LL | int_bool(1, 2);
|
||||
| ^^^^^^^^ - argument of type `{integer}` unexpected
|
||||
|
|
||||
note: expected tuple, found integer
|
||||
note: expected `(i32, bool)`, found integer
|
||||
--> $DIR/args-instead-of-tuple-errors.rs:8:14
|
||||
|
|
||||
LL | int_bool(1, 2);
|
||||
|
@ -65,7 +65,7 @@ error[E0308]: mismatched types
|
|||
--> $DIR/args-instead-of-tuple-errors.rs:14:34
|
||||
|
|
||||
LL | let _: Option<(i32,)> = Some(5_usize);
|
||||
| ---- ^^^^^^^ expected tuple, found `usize`
|
||||
| ---- ^^^^^^^ expected `(i32,)`, found `usize`
|
||||
| |
|
||||
| arguments to this enum variant are incorrect
|
||||
|
|
||||
|
@ -85,7 +85,7 @@ error[E0308]: mismatched types
|
|||
--> $DIR/args-instead-of-tuple-errors.rs:17:34
|
||||
|
|
||||
LL | let _: Option<(i32,)> = Some((5_usize));
|
||||
| ---- ^^^^^^^^^ expected tuple, found `usize`
|
||||
| ---- ^^^^^^^^^ expected `(i32,)`, found `usize`
|
||||
| |
|
||||
| arguments to this enum variant are incorrect
|
||||
|
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue