summaryrefslogtreecommitdiffstats
path: root/src/test/ui/argument-suggestions/extra_arguments.stderr
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/ui/argument-suggestions/extra_arguments.stderr')
-rw-r--r--src/test/ui/argument-suggestions/extra_arguments.stderr239
1 files changed, 239 insertions, 0 deletions
diff --git a/src/test/ui/argument-suggestions/extra_arguments.stderr b/src/test/ui/argument-suggestions/extra_arguments.stderr
new file mode 100644
index 000000000..32b1e1573
--- /dev/null
+++ b/src/test/ui/argument-suggestions/extra_arguments.stderr
@@ -0,0 +1,239 @@
+error[E0061]: this function takes 0 arguments but 1 argument was supplied
+ --> $DIR/extra_arguments.rs:7:3
+ |
+LL | empty("");
+ | ^^^^^ -- argument of type `&'static str` unexpected
+ |
+note: function defined here
+ --> $DIR/extra_arguments.rs:1:4
+ |
+LL | fn empty() {}
+ | ^^^^^
+help: remove the extra argument
+ |
+LL | empty();
+ | ~~~~~~~
+
+error[E0061]: this function takes 1 argument but 2 arguments were supplied
+ --> $DIR/extra_arguments.rs:9:3
+ |
+LL | one_arg(1, 1);
+ | ^^^^^^^ - argument of type `{integer}` unexpected
+ |
+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
+ |
+LL | one_arg(1, "");
+ | ^^^^^^^ -- argument of type `&'static str` unexpected
+ |
+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
+ |
+LL | one_arg(1, "", 1.0);
+ | ^^^^^^^ -- --- argument of type `{float}` unexpected
+ | |
+ | argument of type `&'static str` unexpected
+ |
+note: function defined here
+ --> $DIR/extra_arguments.rs:2:4
+ |
+LL | fn one_arg(_a: i32) {}
+ | ^^^^^^^ -------
+help: remove the extra arguments
+ |
+LL | one_arg(1);
+ | ~~~~~~~~~~
+
+error[E0061]: this function takes 2 arguments but 3 arguments were supplied
+ --> $DIR/extra_arguments.rs:13:3
+ |
+LL | two_arg_same(1, 1, 1);
+ | ^^^^^^^^^^^^ - argument of type `{integer}` unexpected
+ |
+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
+ |
+LL | two_arg_same(1, 1, 1.0);
+ | ^^^^^^^^^^^^ --- argument of type `{float}` unexpected
+ |
+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
+ |
+LL | two_arg_diff(1, 1, "");
+ | ^^^^^^^^^^^^ - argument of type `{integer}` unexpected
+ |
+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
+ |
+LL | two_arg_diff(1, "", "");
+ | ^^^^^^^^^^^^ -- argument of type `&'static str` unexpected
+ |
+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
+ |
+LL | two_arg_diff(1, 1, "", "");
+ | ^^^^^^^^^^^^ - -- argument of type `&'static str` unexpected
+ | |
+ | argument of type `{integer}` unexpected
+ |
+note: function defined here
+ --> $DIR/extra_arguments.rs:4:4
+ |
+LL | fn two_arg_diff(_a: i32, _b: &str) {}
+ | ^^^^^^^^^^^^ ------- --------
+help: remove the extra arguments
+ |
+LL | two_arg_diff(1, "");
+ | ~~~~~~~~~~~~~~~~~~~
+
+error[E0061]: this function takes 2 arguments but 4 arguments were supplied
+ --> $DIR/extra_arguments.rs:19:3
+ |
+LL | two_arg_diff(1, "", 1, "");
+ | ^^^^^^^^^^^^ - -- argument of type `&'static str` unexpected
+ | |
+ | argument of type `{integer}` unexpected
+ |
+note: function defined here
+ --> $DIR/extra_arguments.rs:4:4
+ |
+LL | fn two_arg_diff(_a: i32, _b: &str) {}
+ | ^^^^^^^^^^^^ ------- --------
+help: remove the extra arguments
+ |
+LL | two_arg_diff(1, "");
+ | ~~~~~~~~~~~~~~~~~~~
+
+error[E0061]: this function takes 2 arguments but 3 arguments were supplied
+ --> $DIR/extra_arguments.rs:22:3
+ |
+LL | two_arg_same(1, 1, "");
+ | ^^^^^^^^^^^^ -- argument of type `&'static str` unexpected
+ |
+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
+ |
+LL | two_arg_diff(1, 1, "");
+ | ^^^^^^^^^^^^ - argument of type `{integer}` unexpected
+ |
+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
+ |
+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
+ |
+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: aborting due to 14 previous errors
+
+For more information about this error, try `rustc --explain E0061`.