From 698f8c2f01ea549d77d7dc3338a12e04c11057b9 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Wed, 17 Apr 2024 14:02:58 +0200 Subject: Adding upstream version 1.64.0+dfsg1. Signed-off-by: Daniel Baumann --- .../argument-suggestions/missing_arguments.stderr | 310 +++++++++++++++++++++ 1 file changed, 310 insertions(+) create mode 100644 src/test/ui/argument-suggestions/missing_arguments.stderr (limited to 'src/test/ui/argument-suggestions/missing_arguments.stderr') diff --git a/src/test/ui/argument-suggestions/missing_arguments.stderr b/src/test/ui/argument-suggestions/missing_arguments.stderr new file mode 100644 index 000000000..2509d22d7 --- /dev/null +++ b/src/test/ui/argument-suggestions/missing_arguments.stderr @@ -0,0 +1,310 @@ +error[E0061]: this function takes 1 argument but 0 arguments were supplied + --> $DIR/missing_arguments.rs:10:3 + | +LL | one_arg(); + | ^^^^^^^-- an argument of type `i32` is missing + | +note: function defined here + --> $DIR/missing_arguments.rs:1:4 + | +LL | fn one_arg(_a: i32) {} + | ^^^^^^^ ------- +help: provide the argument + | +LL | one_arg(/* i32 */); + | ~~~~~~~~~~~~~~~~~~ + +error[E0061]: this function takes 2 arguments but 0 arguments were supplied + --> $DIR/missing_arguments.rs:14:3 + | +LL | two_same( ); + | ^^^^^^^^----------------- two arguments of type `i32` and `i32` are missing + | +note: function defined here + --> $DIR/missing_arguments.rs:2:4 + | +LL | fn two_same(_a: i32, _b: i32) {} + | ^^^^^^^^ ------- ------- +help: provide the arguments + | +LL | two_same(/* i32 */, /* i32 */); + | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +error[E0061]: this function takes 2 arguments but 1 argument was supplied + --> $DIR/missing_arguments.rs:15:3 + | +LL | two_same( 1 ); + | ^^^^^^^^----------------- an argument of type `i32` is missing + | +note: function defined here + --> $DIR/missing_arguments.rs:2:4 + | +LL | fn two_same(_a: i32, _b: i32) {} + | ^^^^^^^^ ------- ------- +help: provide the argument + | +LL | two_same(1, /* i32 */); + | ~~~~~~~~~~~~~~~~~~~~~~ + +error[E0061]: this function takes 2 arguments but 0 arguments were supplied + --> $DIR/missing_arguments.rs:16:3 + | +LL | two_diff( ); + | ^^^^^^^^----------------- two arguments of type `i32` and `f32` are missing + | +note: function defined here + --> $DIR/missing_arguments.rs:3:4 + | +LL | fn two_diff(_a: i32, _b: f32) {} + | ^^^^^^^^ ------- ------- +help: provide the arguments + | +LL | two_diff(/* i32 */, /* f32 */); + | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +error[E0061]: this function takes 2 arguments but 1 argument was supplied + --> $DIR/missing_arguments.rs:17:3 + | +LL | two_diff( 1 ); + | ^^^^^^^^----------------- an argument of type `f32` is missing + | +note: function defined here + --> $DIR/missing_arguments.rs:3:4 + | +LL | fn two_diff(_a: i32, _b: f32) {} + | ^^^^^^^^ ------- ------- +help: provide the argument + | +LL | two_diff(1, /* f32 */); + | ~~~~~~~~~~~~~~~~~~~~~~ + +error[E0061]: this function takes 2 arguments but 1 argument was supplied + --> $DIR/missing_arguments.rs:18:3 + | +LL | two_diff( 1.0 ); + | ^^^^^^^^ --- an argument of type `i32` is missing + | +note: function defined here + --> $DIR/missing_arguments.rs:3:4 + | +LL | fn two_diff(_a: i32, _b: f32) {} + | ^^^^^^^^ ------- ------- +help: provide the argument + | +LL | two_diff(/* i32 */, 1.0); + | ~~~~~~~~~~~~~~~~~~~~~~~~ + +error[E0061]: this function takes 3 arguments but 0 arguments were supplied + --> $DIR/missing_arguments.rs:21:3 + | +LL | three_same( ); + | ^^^^^^^^^^------------------------- three arguments of type `i32`, `i32`, and `i32` are missing + | +note: function defined here + --> $DIR/missing_arguments.rs:4:4 + | +LL | fn three_same(_a: i32, _b: i32, _c: i32) {} + | ^^^^^^^^^^ ------- ------- ------- +help: provide the arguments + | +LL | three_same(/* i32 */, /* i32 */, /* i32 */); + | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +error[E0061]: this function takes 3 arguments but 1 argument was supplied + --> $DIR/missing_arguments.rs:22:3 + | +LL | three_same( 1 ); + | ^^^^^^^^^^------------------------- two arguments of type `i32` and `i32` are missing + | +note: function defined here + --> $DIR/missing_arguments.rs:4:4 + | +LL | fn three_same(_a: i32, _b: i32, _c: i32) {} + | ^^^^^^^^^^ ------- ------- ------- +help: provide the arguments + | +LL | three_same(1, /* i32 */, /* i32 */); + | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +error[E0061]: this function takes 3 arguments but 2 arguments were supplied + --> $DIR/missing_arguments.rs:23:3 + | +LL | three_same( 1, 1 ); + | ^^^^^^^^^^------------------------- an argument of type `i32` is missing + | +note: function defined here + --> $DIR/missing_arguments.rs:4:4 + | +LL | fn three_same(_a: i32, _b: i32, _c: i32) {} + | ^^^^^^^^^^ ------- ------- ------- +help: provide the argument + | +LL | three_same(1, 1, /* i32 */); + | ~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +error[E0061]: this function takes 3 arguments but 2 arguments were supplied + --> $DIR/missing_arguments.rs:26:3 + | +LL | three_diff( 1.0, "" ); + | ^^^^^^^^^^ --- an argument of type `i32` is missing + | +note: function defined here + --> $DIR/missing_arguments.rs:5:4 + | +LL | fn three_diff(_a: i32, _b: f32, _c: &str) {} + | ^^^^^^^^^^ ------- ------- -------- +help: provide the argument + | +LL | three_diff(/* i32 */, 1.0, ""); + | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +error[E0061]: this function takes 3 arguments but 2 arguments were supplied + --> $DIR/missing_arguments.rs:27:3 + | +LL | three_diff( 1, "" ); + | ^^^^^^^^^^ -- an argument of type `f32` is missing + | +note: function defined here + --> $DIR/missing_arguments.rs:5:4 + | +LL | fn three_diff(_a: i32, _b: f32, _c: &str) {} + | ^^^^^^^^^^ ------- ------- -------- +help: provide the argument + | +LL | three_diff(1, /* f32 */, ""); + | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +error[E0061]: this function takes 3 arguments but 2 arguments were supplied + --> $DIR/missing_arguments.rs:28:3 + | +LL | three_diff( 1, 1.0 ); + | ^^^^^^^^^^------------------------- an argument of type `&str` is missing + | +note: function defined here + --> $DIR/missing_arguments.rs:5:4 + | +LL | fn three_diff(_a: i32, _b: f32, _c: &str) {} + | ^^^^^^^^^^ ------- ------- -------- +help: provide the argument + | +LL | three_diff(1, 1.0, /* &str */); + | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +error[E0061]: this function takes 3 arguments but 1 argument was supplied + --> $DIR/missing_arguments.rs:29:3 + | +LL | three_diff( "" ); + | ^^^^^^^^^^------------------------- two arguments of type `i32` and `f32` are missing + | +note: function defined here + --> $DIR/missing_arguments.rs:5:4 + | +LL | fn three_diff(_a: i32, _b: f32, _c: &str) {} + | ^^^^^^^^^^ ------- ------- -------- +help: provide the arguments + | +LL | three_diff(/* i32 */, /* f32 */, ""); + | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +error[E0061]: this function takes 3 arguments but 1 argument was supplied + --> $DIR/missing_arguments.rs:30:3 + | +LL | three_diff( 1.0 ); + | ^^^^^^^^^^------------------------- + | | | + | | an argument of type `i32` is missing + | an argument of type `&str` is missing + | +note: function defined here + --> $DIR/missing_arguments.rs:5:4 + | +LL | fn three_diff(_a: i32, _b: f32, _c: &str) {} + | ^^^^^^^^^^ ------- ------- -------- +help: provide the arguments + | +LL | three_diff(/* i32 */, 1.0, /* &str */); + | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +error[E0061]: this function takes 3 arguments but 1 argument was supplied + --> $DIR/missing_arguments.rs:31:3 + | +LL | three_diff( 1 ); + | ^^^^^^^^^^------------------------- two arguments of type `f32` and `&str` are missing + | +note: function defined here + --> $DIR/missing_arguments.rs:5:4 + | +LL | fn three_diff(_a: i32, _b: f32, _c: &str) {} + | ^^^^^^^^^^ ------- ------- -------- +help: provide the arguments + | +LL | three_diff(1, /* f32 */, /* &str */); + | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +error[E0061]: this function takes 4 arguments but 0 arguments were supplied + --> $DIR/missing_arguments.rs:34:3 + | +LL | four_repeated( ); + | ^^^^^^^^^^^^^--------------------------------- multiple arguments are missing + | +note: function defined here + --> $DIR/missing_arguments.rs:6:4 + | +LL | fn four_repeated(_a: i32, _b: f32, _c: f32, _d: &str) {} + | ^^^^^^^^^^^^^ ------- ------- ------- -------- +help: provide the arguments + | +LL | four_repeated(/* i32 */, /* f32 */, /* f32 */, /* &str */); + | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +error[E0061]: this function takes 4 arguments but 2 arguments were supplied + --> $DIR/missing_arguments.rs:35:3 + | +LL | four_repeated( 1, "" ); + | ^^^^^^^^^^^^^--------------------------------- two arguments of type `f32` and `f32` are missing + | +note: function defined here + --> $DIR/missing_arguments.rs:6:4 + | +LL | fn four_repeated(_a: i32, _b: f32, _c: f32, _d: &str) {} + | ^^^^^^^^^^^^^ ------- ------- ------- -------- +help: provide the arguments + | +LL | four_repeated(1, /* f32 */, /* f32 */, ""); + | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +error[E0061]: this function takes 5 arguments but 0 arguments were supplied + --> $DIR/missing_arguments.rs:38:3 + | +LL | complex( ); + | ^^^^^^^--------------------------------- multiple arguments are missing + | +note: function defined here + --> $DIR/missing_arguments.rs:7:4 + | +LL | fn complex(_a: i32, _b: f32, _c: i32, _d: f32, _e: &str) {} + | ^^^^^^^ ------- ------- ------- ------- -------- +help: provide the arguments + | +LL | complex(/* i32 */, /* f32 */, /* i32 */, /* f32 */, /* &str */); + | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +error[E0061]: this function takes 5 arguments but 2 arguments were supplied + --> $DIR/missing_arguments.rs:39:3 + | +LL | complex( 1, "" ); + | ^^^^^^^--------------------------------- three arguments of type `f32`, `i32`, and `f32` are missing + | +note: function defined here + --> $DIR/missing_arguments.rs:7:4 + | +LL | fn complex(_a: i32, _b: f32, _c: i32, _d: f32, _e: &str) {} + | ^^^^^^^ ------- ------- ------- ------- -------- +help: provide the arguments + | +LL | complex(1, /* f32 */, /* i32 */, /* f32 */, ""); + | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +error: aborting due to 19 previous errors + +For more information about this error, try `rustc --explain E0061`. -- cgit v1.2.3