summaryrefslogtreecommitdiffstats
path: root/tests/ui/argument-suggestions/extra_arguments.stderr
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-17 12:19:41 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-17 12:19:41 +0000
commit4f9fe856a25ab29345b90e7725509e9ee38a37be (patch)
treee4ffd8a9374cae7b21f7cbfb352927e0e074aff6 /tests/ui/argument-suggestions/extra_arguments.stderr
parentAdding upstream version 1.68.2+dfsg1. (diff)
downloadrustc-upstream/1.69.0+dfsg1.tar.xz
rustc-upstream/1.69.0+dfsg1.zip
Adding upstream version 1.69.0+dfsg1.upstream/1.69.0+dfsg1
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'tests/ui/argument-suggestions/extra_arguments.stderr')
-rw-r--r--tests/ui/argument-suggestions/extra_arguments.stderr214
1 files changed, 124 insertions, 90 deletions
diff --git a/tests/ui/argument-suggestions/extra_arguments.stderr b/tests/ui/argument-suggestions/extra_arguments.stderr
index 48787b0c3..11c710997 100644
--- a/tests/ui/argument-suggestions/extra_arguments.stderr
+++ b/tests/ui/argument-suggestions/extra_arguments.stderr
@@ -1,58 +1,74 @@
error[E0061]: this function takes 0 arguments but 1 argument was supplied
- --> $DIR/extra_arguments.rs:7:3
+ --> $DIR/extra_arguments.rs:13:3
|
LL | empty("");
- | ^^^^^ -- argument of type `&'static str` unexpected
+ | ^^^^^ --
+ | |
+ | unexpected argument of type `&'static str`
+ | help: remove the extra argument
|
note: function defined here
--> $DIR/extra_arguments.rs:1:4
|
LL | fn empty() {}
| ^^^^^
-help: remove the extra argument
+
+error[E0061]: this function takes 0 arguments but 2 arguments were supplied
+ --> $DIR/extra_arguments.rs:14:3
+ |
+LL | empty(1, 1);
+ | ^^^^^ - - unexpected argument of type `{integer}`
+ | |
+ | unexpected argument of type `{integer}`
+ |
+note: function defined here
+ --> $DIR/extra_arguments.rs:1:4
+ |
+LL | fn empty() {}
+ | ^^^^^
+help: remove the extra arguments
+ |
+LL - empty(1, 1);
+LL + empty();
|
-LL | empty();
- | ~~
error[E0061]: this function takes 1 argument but 2 arguments were supplied
- --> $DIR/extra_arguments.rs:9:3
+ --> $DIR/extra_arguments.rs:16:3
|
LL | one_arg(1, 1);
- | ^^^^^^^ - argument of type `{integer}` unexpected
+ | ^^^^^^^ ---
+ | | |
+ | | unexpected argument of type `{integer}`
+ | help: remove the extra argument
|
note: function defined here
--> $DIR/extra_arguments.rs:2:4
|
LL | fn one_arg(_a: i32) {}
| ^^^^^^^ -------
-help: remove the extra argument
- |
-LL | one_arg(1);
- | ~~~
error[E0061]: this function takes 1 argument but 2 arguments were supplied
- --> $DIR/extra_arguments.rs:10:3
+ --> $DIR/extra_arguments.rs:17:3
|
LL | one_arg(1, "");
- | ^^^^^^^ -- argument of type `&'static str` unexpected
+ | ^^^^^^^ ----
+ | | |
+ | | unexpected argument of type `&'static str`
+ | help: remove the extra argument
|
note: function defined here
--> $DIR/extra_arguments.rs:2:4
|
LL | fn one_arg(_a: i32) {}
| ^^^^^^^ -------
-help: remove the extra argument
- |
-LL | one_arg(1);
- | ~~~
error[E0061]: this function takes 1 argument but 3 arguments were supplied
- --> $DIR/extra_arguments.rs:11:3
+ --> $DIR/extra_arguments.rs:18:3
|
LL | one_arg(1, "", 1.0);
- | ^^^^^^^ -- --- argument of type `{float}` unexpected
+ | ^^^^^^^ -- --- unexpected argument of type `{float}`
| |
- | argument of type `&'static str` unexpected
+ | unexpected argument of type `&'static str`
|
note: function defined here
--> $DIR/extra_arguments.rs:2:4
@@ -61,80 +77,77 @@ LL | fn one_arg(_a: i32) {}
| ^^^^^^^ -------
help: remove the extra arguments
|
-LL | one_arg(1);
- | ~~~
+LL - one_arg(1, "", 1.0);
+LL + one_arg(1);
+ |
error[E0061]: this function takes 2 arguments but 3 arguments were supplied
- --> $DIR/extra_arguments.rs:13:3
+ --> $DIR/extra_arguments.rs:20:3
|
LL | two_arg_same(1, 1, 1);
- | ^^^^^^^^^^^^ - argument of type `{integer}` unexpected
+ | ^^^^^^^^^^^^ ---
+ | | |
+ | | unexpected argument of type `{integer}`
+ | help: remove the extra argument
|
note: function defined here
--> $DIR/extra_arguments.rs:3:4
|
LL | fn two_arg_same(_a: i32, _b: i32) {}
| ^^^^^^^^^^^^ ------- -------
-help: remove the extra argument
- |
-LL | two_arg_same(1, 1);
- | ~~~~~~
error[E0061]: this function takes 2 arguments but 3 arguments were supplied
- --> $DIR/extra_arguments.rs:14:3
+ --> $DIR/extra_arguments.rs:21:3
|
LL | two_arg_same(1, 1, 1.0);
- | ^^^^^^^^^^^^ --- argument of type `{float}` unexpected
+ | ^^^^^^^^^^^^ -----
+ | | |
+ | | unexpected argument of type `{float}`
+ | help: remove the extra argument
|
note: function defined here
--> $DIR/extra_arguments.rs:3:4
|
LL | fn two_arg_same(_a: i32, _b: i32) {}
| ^^^^^^^^^^^^ ------- -------
-help: remove the extra argument
- |
-LL | two_arg_same(1, 1);
- | ~~~~~~
error[E0061]: this function takes 2 arguments but 3 arguments were supplied
- --> $DIR/extra_arguments.rs:16:3
+ --> $DIR/extra_arguments.rs:23:3
|
LL | two_arg_diff(1, 1, "");
- | ^^^^^^^^^^^^ - argument of type `{integer}` unexpected
+ | ^^^^^^^^^^^^ ---
+ | | |
+ | | unexpected argument of type `{integer}`
+ | help: remove the extra argument
|
note: function defined here
--> $DIR/extra_arguments.rs:4:4
|
LL | fn two_arg_diff(_a: i32, _b: &str) {}
| ^^^^^^^^^^^^ ------- --------
-help: remove the extra argument
- |
-LL | two_arg_diff(1, "");
- | ~~~~~~~
error[E0061]: this function takes 2 arguments but 3 arguments were supplied
- --> $DIR/extra_arguments.rs:17:3
+ --> $DIR/extra_arguments.rs:24:3
|
LL | two_arg_diff(1, "", "");
- | ^^^^^^^^^^^^ -- argument of type `&'static str` unexpected
+ | ^^^^^^^^^^^^ ----
+ | | |
+ | | unexpected argument of type `&'static str`
+ | help: remove the extra argument
|
note: function defined here
--> $DIR/extra_arguments.rs:4:4
|
LL | fn two_arg_diff(_a: i32, _b: &str) {}
| ^^^^^^^^^^^^ ------- --------
-help: remove the extra argument
- |
-LL | two_arg_diff(1, "");
- | ~~~~~~~
error[E0061]: this function takes 2 arguments but 4 arguments were supplied
- --> $DIR/extra_arguments.rs:18:3
+ --> $DIR/extra_arguments.rs:25:3
|
LL | two_arg_diff(1, 1, "", "");
- | ^^^^^^^^^^^^ - -- argument of type `&'static str` unexpected
+ | ^^^^^^^^^^^^ - -- unexpected argument of type `&'static str`
| |
- | argument of type `{integer}` unexpected
+ | unexpected argument of type `{integer}`
|
note: function defined here
--> $DIR/extra_arguments.rs:4:4
@@ -143,16 +156,17 @@ LL | fn two_arg_diff(_a: i32, _b: &str) {}
| ^^^^^^^^^^^^ ------- --------
help: remove the extra arguments
|
-LL | two_arg_diff(1, "");
- | ~~~~~~~
+LL - two_arg_diff(1, 1, "", "");
+LL + two_arg_diff(1, "");
+ |
error[E0061]: this function takes 2 arguments but 4 arguments were supplied
- --> $DIR/extra_arguments.rs:19:3
+ --> $DIR/extra_arguments.rs:26:3
|
LL | two_arg_diff(1, "", 1, "");
- | ^^^^^^^^^^^^ - -- argument of type `&'static str` unexpected
+ | ^^^^^^^^^^^^ - -- unexpected argument of type `&'static str`
| |
- | argument of type `{integer}` unexpected
+ | unexpected argument of type `{integer}`
|
note: function defined here
--> $DIR/extra_arguments.rs:4:4
@@ -161,79 +175,99 @@ LL | fn two_arg_diff(_a: i32, _b: &str) {}
| ^^^^^^^^^^^^ ------- --------
help: remove the extra arguments
|
-LL | two_arg_diff(1, "");
- | ~~~~~~~
+LL - two_arg_diff(1, "", 1, "");
+LL + two_arg_diff(1, "");
+ |
error[E0061]: this function takes 2 arguments but 3 arguments were supplied
- --> $DIR/extra_arguments.rs:22:3
+ --> $DIR/extra_arguments.rs:29:3
|
LL | two_arg_same(1, 1, "");
- | ^^^^^^^^^^^^ -- argument of type `&'static str` unexpected
+ | ^^^^^^^^^^^^ --------
+ | | |
+ | | unexpected argument of type `&'static str`
+ | help: remove the extra argument
|
note: function defined here
--> $DIR/extra_arguments.rs:3:4
|
LL | fn two_arg_same(_a: i32, _b: i32) {}
| ^^^^^^^^^^^^ ------- -------
-help: remove the extra argument
- |
-LL | two_arg_same(1, 1);
- | ~~~~~~
error[E0061]: this function takes 2 arguments but 3 arguments were supplied
- --> $DIR/extra_arguments.rs:23:3
+ --> $DIR/extra_arguments.rs:30:3
|
LL | two_arg_diff(1, 1, "");
- | ^^^^^^^^^^^^ - argument of type `{integer}` unexpected
+ | ^^^^^^^^^^^^ ---
+ | | |
+ | | unexpected argument of type `{integer}`
+ | help: remove the extra argument
|
note: function defined here
--> $DIR/extra_arguments.rs:4:4
|
LL | fn two_arg_diff(_a: i32, _b: &str) {}
| ^^^^^^^^^^^^ ------- --------
-help: remove the extra argument
- |
-LL | two_arg_diff(1, "");
- | ~~~~~~~
error[E0061]: this function takes 2 arguments but 3 arguments were supplied
- --> $DIR/extra_arguments.rs:24:3
- |
-LL | two_arg_same(
- | ^^^^^^^^^^^^
-...
-LL | ""
- | -- argument of type `&'static str` unexpected
+ --> $DIR/extra_arguments.rs:31:3
+ |
+LL | two_arg_same(
+ | ^^^^^^^^^^^^
+LL | 1,
+LL | 1,
+ | ______-
+LL | | ""
+ | | --
+ | |_____||
+ | |help: remove the extra argument
+ | unexpected argument of type `&'static str`
|
note: function defined here
--> $DIR/extra_arguments.rs:3:4
|
LL | fn two_arg_same(_a: i32, _b: i32) {}
| ^^^^^^^^^^^^ ------- -------
-help: remove the extra argument
- |
-LL | two_arg_same(1, 1);
- | ~~~~~~
error[E0061]: this function takes 2 arguments but 3 arguments were supplied
- --> $DIR/extra_arguments.rs:30:3
- |
-LL | two_arg_diff(
- | ^^^^^^^^^^^^
-LL | 1,
-LL | 1,
- | - argument of type `{integer}` unexpected
+ --> $DIR/extra_arguments.rs:37:3
+ |
+LL | two_arg_diff(
+ | ^^^^^^^^^^^^
+LL | 1,
+ | ______-
+LL | | 1,
+ | | -
+ | | |
+ | |_____unexpected argument of type `{integer}`
+ | help: remove the extra argument
|
note: function defined here
--> $DIR/extra_arguments.rs:4:4
|
LL | fn two_arg_diff(_a: i32, _b: &str) {}
| ^^^^^^^^^^^^ ------- --------
-help: remove the extra argument
+
+error[E0061]: this function takes 0 arguments but 2 arguments were supplied
+ --> $DIR/extra_arguments.rs:8:9
+ |
+LL | empty($x, 1);
+ | ^^^^^ - unexpected argument of type `{integer}`
+...
+LL | foo!(1);
+ | -------
+ | | |
+ | | unexpected argument of type `{integer}`
+ | | help: remove the extra argument
+ | in this macro invocation
+ |
+note: function defined here
+ --> $DIR/extra_arguments.rs:1:4
|
-LL | two_arg_diff(1, "");
- | ~~~~~~~
+LL | fn empty() {}
+ | ^^^^^
+ = note: this error originates in the macro `foo` (in Nightly builds, run with -Z macro-backtrace for more info)
-error: aborting due to 14 previous errors
+error: aborting due to 16 previous errors
For more information about this error, try `rustc --explain E0061`.