2019-02-07 13:59:59 +00:00
|
|
|
error[E0401]: can't use generic parameters from outer function
|
2018-12-25 15:56:47 +00:00
|
|
|
--> $DIR/nested-ty-params.rs:3:16
|
2018-08-08 12:28:26 +00:00
|
|
|
|
|
|
|
|
LL | fn hd<U>(v: Vec<U> ) -> U {
|
2019-04-17 10:19:58 +00:00
|
|
|
| - type parameter from outer function
|
2018-08-08 12:28:26 +00:00
|
|
|
LL | fn hd1(w: [U]) -> U { return w[0]; }
|
2022-07-14 13:09:30 +00:00
|
|
|
| - ^ use of generic parameter from outer function
|
|
|
|
| |
|
|
|
|
| help: try using a local generic parameter instead: `<U>`
|
2018-08-08 12:28:26 +00:00
|
|
|
|
2019-02-07 13:59:59 +00:00
|
|
|
error[E0401]: can't use generic parameters from outer function
|
2018-12-25 15:56:47 +00:00
|
|
|
--> $DIR/nested-ty-params.rs:3:23
|
2018-08-08 12:28:26 +00:00
|
|
|
|
|
|
|
|
LL | fn hd<U>(v: Vec<U> ) -> U {
|
2019-04-17 10:19:58 +00:00
|
|
|
| - type parameter from outer function
|
2018-08-08 12:28:26 +00:00
|
|
|
LL | fn hd1(w: [U]) -> U { return w[0]; }
|
2022-07-14 13:09:30 +00:00
|
|
|
| - ^ use of generic parameter from outer function
|
|
|
|
| |
|
|
|
|
| help: try using a local generic parameter instead: `<U>`
|
2018-08-08 12:28:26 +00:00
|
|
|
|
2018-08-22 23:19:38 +00:00
|
|
|
error: aborting due to 2 previous errors
|
2018-08-08 12:28:26 +00:00
|
|
|
|
2018-08-22 23:19:38 +00:00
|
|
|
For more information about this error, try `rustc --explain E0401`.
|