2023-08-14 13:09:53 +00:00
|
|
|
error[E0283]: type annotations needed
|
2022-02-14 13:25:26 +01:00
|
|
|
--> $DIR/issue-83249.rs:19:9
|
2021-10-18 18:25:45 +02:00
|
|
|
|
|
|
|
|
LL | let _ = foo([0; 1]);
|
2023-08-14 13:09:53 +00:00
|
|
|
| ^ --- ------ type must be known at this point
|
|
|
|
| |
|
|
|
|
| required by a bound introduced by this call
|
2022-05-20 13:49:41 +09:00
|
|
|
|
|
2023-08-14 13:09:53 +00:00
|
|
|
= note: cannot satisfy `_: Foo`
|
|
|
|
= help: the trait `Foo` is implemented for `u8`
|
|
|
|
note: required by a bound in `foo`
|
|
|
|
--> $DIR/issue-83249.rs:12:11
|
|
|
|
|
|
|
|
|
LL | fn foo<T: Foo>(_: [u8; T::N]) -> T {
|
|
|
|
| ^^^ required by this bound in `foo`
|
2022-12-13 11:36:43 -08:00
|
|
|
help: consider giving this pattern a type
|
2022-05-20 13:49:41 +09:00
|
|
|
|
|
2022-12-13 11:36:43 -08:00
|
|
|
LL | let _: /* Type */ = foo([0; 1]);
|
|
|
|
| ++++++++++++
|
2021-10-18 18:25:45 +02:00
|
|
|
|
|
|
|
error: aborting due to previous error
|
|
|
|
|
2023-08-14 13:09:53 +00:00
|
|
|
For more information about this error, try `rustc --explain E0283`.
|