1
1
error[E0061]: this function takes 0 arguments but 1 argument was supplied
2
- --> $DIR/extra_arguments.rs:13 :3
2
+ --> $DIR/extra_arguments.rs:19 :3
3
3
|
4
4
LL | empty("");
5
5
| ^^^^^ --
@@ -14,7 +14,7 @@ LL | fn empty() {}
14
14
| ^^^^^
15
15
16
16
error[E0061]: this function takes 0 arguments but 2 arguments were supplied
17
- --> $DIR/extra_arguments.rs:14 :3
17
+ --> $DIR/extra_arguments.rs:20 :3
18
18
|
19
19
LL | empty(1, 1);
20
20
| ^^^^^ - - unexpected argument of type `{integer}`
@@ -33,7 +33,7 @@ LL + empty();
33
33
|
34
34
35
35
error[E0061]: this function takes 1 argument but 2 arguments were supplied
36
- --> $DIR/extra_arguments.rs:16 :3
36
+ --> $DIR/extra_arguments.rs:22 :3
37
37
|
38
38
LL | one_arg(1, 1);
39
39
| ^^^^^^^ ---
@@ -48,7 +48,7 @@ LL | fn one_arg(_a: i32) {}
48
48
| ^^^^^^^ -------
49
49
50
50
error[E0061]: this function takes 1 argument but 2 arguments were supplied
51
- --> $DIR/extra_arguments.rs:17 :3
51
+ --> $DIR/extra_arguments.rs:23 :3
52
52
|
53
53
LL | one_arg(1, "");
54
54
| ^^^^^^^ ----
@@ -63,7 +63,7 @@ LL | fn one_arg(_a: i32) {}
63
63
| ^^^^^^^ -------
64
64
65
65
error[E0061]: this function takes 1 argument but 3 arguments were supplied
66
- --> $DIR/extra_arguments.rs:18 :3
66
+ --> $DIR/extra_arguments.rs:24 :3
67
67
|
68
68
LL | one_arg(1, "", 1.0);
69
69
| ^^^^^^^ -- --- unexpected argument of type `{float}`
@@ -82,7 +82,7 @@ LL + one_arg(1);
82
82
|
83
83
84
84
error[E0061]: this function takes 2 arguments but 3 arguments were supplied
85
- --> $DIR/extra_arguments.rs:20 :3
85
+ --> $DIR/extra_arguments.rs:26 :3
86
86
|
87
87
LL | two_arg_same(1, 1, 1);
88
88
| ^^^^^^^^^^^^ ---
@@ -97,7 +97,7 @@ LL | fn two_arg_same(_a: i32, _b: i32) {}
97
97
| ^^^^^^^^^^^^ ------- -------
98
98
99
99
error[E0061]: this function takes 2 arguments but 3 arguments were supplied
100
- --> $DIR/extra_arguments.rs:21 :3
100
+ --> $DIR/extra_arguments.rs:27 :3
101
101
|
102
102
LL | two_arg_same(1, 1, 1.0);
103
103
| ^^^^^^^^^^^^ -----
@@ -112,7 +112,7 @@ LL | fn two_arg_same(_a: i32, _b: i32) {}
112
112
| ^^^^^^^^^^^^ ------- -------
113
113
114
114
error[E0061]: this function takes 2 arguments but 3 arguments were supplied
115
- --> $DIR/extra_arguments.rs:23 :3
115
+ --> $DIR/extra_arguments.rs:29 :3
116
116
|
117
117
LL | two_arg_diff(1, 1, "");
118
118
| ^^^^^^^^^^^^ ---
@@ -127,7 +127,7 @@ LL | fn two_arg_diff(_a: i32, _b: &str) {}
127
127
| ^^^^^^^^^^^^ ------- --------
128
128
129
129
error[E0061]: this function takes 2 arguments but 3 arguments were supplied
130
- --> $DIR/extra_arguments.rs:24 :3
130
+ --> $DIR/extra_arguments.rs:30 :3
131
131
|
132
132
LL | two_arg_diff(1, "", "");
133
133
| ^^^^^^^^^^^^ ----
@@ -142,7 +142,7 @@ LL | fn two_arg_diff(_a: i32, _b: &str) {}
142
142
| ^^^^^^^^^^^^ ------- --------
143
143
144
144
error[E0061]: this function takes 2 arguments but 4 arguments were supplied
145
- --> $DIR/extra_arguments.rs:25 :3
145
+ --> $DIR/extra_arguments.rs:31 :3
146
146
|
147
147
LL | two_arg_diff(1, 1, "", "");
148
148
| ^^^^^^^^^^^^ - -- unexpected argument of type `&'static str`
@@ -161,7 +161,7 @@ LL + two_arg_diff(1, "");
161
161
|
162
162
163
163
error[E0061]: this function takes 2 arguments but 4 arguments were supplied
164
- --> $DIR/extra_arguments.rs:26 :3
164
+ --> $DIR/extra_arguments.rs:32 :3
165
165
|
166
166
LL | two_arg_diff(1, "", 1, "");
167
167
| ^^^^^^^^^^^^ - -- unexpected argument of type `&'static str`
@@ -180,7 +180,7 @@ LL + two_arg_diff(1, "");
180
180
|
181
181
182
182
error[E0061]: this function takes 2 arguments but 3 arguments were supplied
183
- --> $DIR/extra_arguments.rs:29 :3
183
+ --> $DIR/extra_arguments.rs:35 :3
184
184
|
185
185
LL | two_arg_same(1, 1, "");
186
186
| ^^^^^^^^^^^^ --------
@@ -195,7 +195,7 @@ LL | fn two_arg_same(_a: i32, _b: i32) {}
195
195
| ^^^^^^^^^^^^ ------- -------
196
196
197
197
error[E0061]: this function takes 2 arguments but 3 arguments were supplied
198
- --> $DIR/extra_arguments.rs:30 :3
198
+ --> $DIR/extra_arguments.rs:36 :3
199
199
|
200
200
LL | two_arg_diff(1, 1, "");
201
201
| ^^^^^^^^^^^^ ---
@@ -210,7 +210,7 @@ LL | fn two_arg_diff(_a: i32, _b: &str) {}
210
210
| ^^^^^^^^^^^^ ------- --------
211
211
212
212
error[E0061]: this function takes 2 arguments but 3 arguments were supplied
213
- --> $DIR/extra_arguments.rs:31 :3
213
+ --> $DIR/extra_arguments.rs:37 :3
214
214
|
215
215
LL | two_arg_same(
216
216
| ^^^^^^^^^^^^
@@ -230,7 +230,7 @@ LL | fn two_arg_same(_a: i32, _b: i32) {}
230
230
| ^^^^^^^^^^^^ ------- -------
231
231
232
232
error[E0061]: this function takes 2 arguments but 3 arguments were supplied
233
- --> $DIR/extra_arguments.rs:37 :3
233
+ --> $DIR/extra_arguments.rs:43 :3
234
234
|
235
235
LL | two_arg_diff(
236
236
| ^^^^^^^^^^^^
@@ -254,8 +254,8 @@ error[E0061]: this function takes 0 arguments but 2 arguments were supplied
254
254
LL | empty($x, 1);
255
255
| ^^^^^ - unexpected argument of type `{integer}`
256
256
...
257
- LL | foo!(1);
258
- | -------
257
+ LL | foo!(1, ~ );
258
+ | ----------
259
259
| | |
260
260
| | unexpected argument of type `{integer}`
261
261
| | help: remove the extra argument
@@ -268,6 +268,81 @@ LL | fn empty() {}
268
268
| ^^^^^
269
269
= note: this error originates in the macro `foo` (in Nightly builds, run with -Z macro-backtrace for more info)
270
270
271
- error: aborting due to 16 previous errors
271
+ error[E0061]: this function takes 0 arguments but 2 arguments were supplied
272
+ --> $DIR/extra_arguments.rs:14:9
273
+ |
274
+ LL | empty(1, $y);
275
+ | ^^^^^ ----- help: remove the extra argument
276
+ | |
277
+ | unexpected argument of type `{integer}`
278
+ ...
279
+ LL | foo!(~, 1);
280
+ | ----------
281
+ | | |
282
+ | | unexpected argument of type `{integer}`
283
+ | in this macro invocation
284
+ |
285
+ note: function defined here
286
+ --> $DIR/extra_arguments.rs:1:4
287
+ |
288
+ LL | fn empty() {}
289
+ | ^^^^^
290
+ = note: this error originates in the macro `foo` (in Nightly builds, run with -Z macro-backtrace for more info)
291
+
292
+ error[E0061]: this function takes 0 arguments but 2 arguments were supplied
293
+ --> $DIR/extra_arguments.rs:11:9
294
+ |
295
+ LL | empty($x, $y);
296
+ | ^^^^^
297
+ ...
298
+ LL | foo!(1, 1);
299
+ | ----------
300
+ | | | |
301
+ | | | unexpected argument of type `{integer}`
302
+ | | unexpected argument of type `{integer}`
303
+ | in this macro invocation
304
+ |
305
+ note: function defined here
306
+ --> $DIR/extra_arguments.rs:1:4
307
+ |
308
+ LL | fn empty() {}
309
+ | ^^^^^
310
+ = note: this error originates in the macro `foo` (in Nightly builds, run with -Z macro-backtrace for more info)
311
+ help: remove the extra arguments
312
+ |
313
+ LL ~ empty($x, $y;
314
+ LL | };
315
+ ...
316
+ LL | foo!(~, 1);
317
+ LL ~ foo!(, 1);
318
+ |
319
+
320
+ error[E0061]: this function takes 1 argument but 2 arguments were supplied
321
+ --> $DIR/extra_arguments.rs:53:3
322
+ |
323
+ LL | one_arg(1, panic!());
324
+ | ^^^^^^^ -------- unexpected argument
325
+ |
326
+ note: function defined here
327
+ --> $DIR/extra_arguments.rs:2:4
328
+ |
329
+ LL | fn one_arg(_a: i32) {}
330
+ | ^^^^^^^ -------
331
+
332
+ error[E0061]: this function takes 1 argument but 2 arguments were supplied
333
+ --> $DIR/extra_arguments.rs:54:3
334
+ |
335
+ LL | one_arg(panic!(), 1);
336
+ | ^^^^^^^ - - unexpected argument of type `{integer}`
337
+ | |
338
+ | help: remove the extra argument
339
+ |
340
+ note: function defined here
341
+ --> $DIR/extra_arguments.rs:2:4
342
+ |
343
+ LL | fn one_arg(_a: i32) {}
344
+ | ^^^^^^^ -------
345
+
346
+ error: aborting due to 20 previous errors
272
347
273
348
For more information about this error, try `rustc --explain E0061`.
0 commit comments