Files
rust/src/test/ui/suggestions/args-instead-of-tuple-errors.stderr

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

53 lines
1.8 KiB
Plaintext
Raw Normal View History

error[E0061]: this enum variant takes 1 argument but 2 arguments were supplied
--> $DIR/args-instead-of-tuple-errors.rs:6:34
|
LL | let _: Option<(i32, bool)> = Some(1, 2);
| ^^^^ - - supplied 2 arguments
| |
| expected 1 argument
error[E0061]: this function takes 1 argument but 2 arguments were supplied
--> $DIR/args-instead-of-tuple-errors.rs:8:5
|
LL | int_bool(1, 2);
| ^^^^^^^^ - - supplied 2 arguments
| |
| expected 1 argument
|
note: function defined here
2022-01-28 23:27:01 +00:00
--> $DIR/args-instead-of-tuple-errors.rs:21:4
|
LL | fn int_bool(_: (i32, bool)) {
| ^^^^^^^^ --------------
2022-01-16 22:47:33 +00:00
error[E0061]: this enum variant takes 1 argument but 0 arguments were supplied
--> $DIR/args-instead-of-tuple-errors.rs:11:28
|
LL | let _: Option<(i8,)> = Some();
| ^^^^-- supplied 0 arguments
| |
| expected 1 argument
2022-01-28 23:27:01 +00:00
error[E0308]: mismatched types
--> $DIR/args-instead-of-tuple-errors.rs:14:34
|
LL | let _: Option<(i32,)> = Some(5_usize);
| ^^^^^^^ expected tuple, found `usize`
|
= note: expected tuple `(i32,)`
found type `usize`
error[E0308]: mismatched types
--> $DIR/args-instead-of-tuple-errors.rs:17:34
|
LL | let _: Option<(i32,)> = Some((5_usize));
| ^^^^^^^^^ expected tuple, found `usize`
|
= note: expected tuple `(i32,)`
found type `usize`
error: aborting due to 5 previous errors
2022-01-28 23:27:01 +00:00
Some errors have detailed explanations: E0061, E0308.
For more information about an error, try `rustc --explain E0061`.