]> git.lizzy.rs Git - rust.git/blob - src/test/ui/impl-trait/in-trait/wf-bounds.stderr
Rollup merge of #105405 - sunfishcode:sunfishcode/export-dynamic, r=TaKO8Ki
[rust.git] / src / test / ui / impl-trait / in-trait / wf-bounds.stderr
1 error[E0277]: the size for values of type `[u8]` cannot be known at compilation time
2   --> $DIR/wf-bounds.rs:9:22
3    |
4 LL |     fn nya() -> impl Wf<Vec<[u8]>>;
5    |                      ^^^^^^^^^^^^^ doesn't have a size known at compile-time
6    |
7    = help: the trait `Sized` is not implemented for `[u8]`
8 note: required by a bound in `Vec`
9   --> $SRC_DIR/alloc/src/vec/mod.rs:LL:COL
10    |
11 LL | pub struct Vec<T, #[unstable(feature = "allocator_api", issue = "32838")] A: Allocator = Global> {
12    |                ^ required by this bound in `Vec`
13
14 error[E0277]: the size for values of type `[u8]` cannot be known at compilation time
15   --> $DIR/wf-bounds.rs:12:23
16    |
17 LL |     fn nya2() -> impl Wf<[u8]>;
18    |                       ^^^^^^^^ doesn't have a size known at compile-time
19    |
20    = help: the trait `Sized` is not implemented for `[u8]`
21 note: required by a bound in `Wf`
22   --> $DIR/wf-bounds.rs:6:10
23    |
24 LL | trait Wf<T> {}
25    |          ^ required by this bound in `Wf`
26 help: consider relaxing the implicit `Sized` restriction
27    |
28 LL | trait Wf<T: ?Sized> {}
29    |           ++++++++
30
31 error: aborting due to 2 previous errors
32
33 For more information about this error, try `rustc --explain E0277`.