2023-02-23 17:27:06 +00:00
|
|
|
error[E0107]: struct takes 1 lifetime argument but 2 lifetime arguments were supplied
|
2021-01-02 18:45:11 +00:00
|
|
|
--> $DIR/generic-arg-mismatch-recover.rs:6:5
|
2018-08-20 15:32:59 +00:00
|
|
|
|
|
2019-03-09 12:03:44 +00:00
|
|
|
LL | Foo::<'static, 'static, ()>(&0);
|
2021-02-18 20:01:44 +00:00
|
|
|
| ^^^ ------- help: remove this lifetime argument
|
2021-01-02 18:45:11 +00:00
|
|
|
| |
|
|
|
|
| expected 1 lifetime argument
|
|
|
|
|
|
|
|
|
note: struct defined here, with 1 lifetime parameter: `'a`
|
|
|
|
--> $DIR/generic-arg-mismatch-recover.rs:1:8
|
|
|
|
|
|
|
|
|
LL | struct Foo<'a, T: 'a>(&'a T);
|
|
|
|
| ^^^ --
|
2018-08-20 15:32:59 +00:00
|
|
|
|
2023-02-23 17:27:06 +00:00
|
|
|
error[E0107]: struct takes 1 lifetime argument but 2 lifetime arguments were supplied
|
2021-01-02 18:45:11 +00:00
|
|
|
--> $DIR/generic-arg-mismatch-recover.rs:9:5
|
2018-08-20 15:32:59 +00:00
|
|
|
|
|
2019-03-09 12:03:44 +00:00
|
|
|
LL | Bar::<'static, 'static, ()>(&());
|
2021-02-18 20:01:44 +00:00
|
|
|
| ^^^ ------- help: remove this lifetime argument
|
2021-01-02 18:45:11 +00:00
|
|
|
| |
|
|
|
|
| expected 1 lifetime argument
|
|
|
|
|
|
|
|
|
note: struct defined here, with 1 lifetime parameter: `'a`
|
|
|
|
--> $DIR/generic-arg-mismatch-recover.rs:3:8
|
|
|
|
|
|
|
|
|
LL | struct Bar<'a>(&'a ());
|
|
|
|
| ^^^ --
|
2018-08-20 15:32:59 +00:00
|
|
|
|
2023-02-23 17:27:06 +00:00
|
|
|
error[E0107]: struct takes 0 generic arguments but 1 generic argument was supplied
|
2021-01-02 18:45:11 +00:00
|
|
|
--> $DIR/generic-arg-mismatch-recover.rs:9:5
|
2018-08-20 15:32:59 +00:00
|
|
|
|
|
2019-03-09 12:03:44 +00:00
|
|
|
LL | Bar::<'static, 'static, ()>(&());
|
2021-02-18 20:01:44 +00:00
|
|
|
| ^^^ -- help: remove this generic argument
|
2021-01-02 18:45:11 +00:00
|
|
|
| |
|
2021-02-18 20:01:44 +00:00
|
|
|
| expected 0 generic arguments
|
2021-01-02 18:45:11 +00:00
|
|
|
|
|
2021-02-18 20:01:44 +00:00
|
|
|
note: struct defined here, with 0 generic parameters
|
2021-01-02 18:45:11 +00:00
|
|
|
--> $DIR/generic-arg-mismatch-recover.rs:3:8
|
|
|
|
|
|
|
|
|
LL | struct Bar<'a>(&'a ());
|
|
|
|
| ^^^
|
2018-08-20 15:32:59 +00:00
|
|
|
|
2020-01-20 23:59:17 +00:00
|
|
|
error: aborting due to 3 previous errors
|
2018-08-20 15:32:59 +00:00
|
|
|
|
2020-01-20 23:59:17 +00:00
|
|
|
For more information about this error, try `rustc --explain E0107`.
|