]> git.proxmox.com Git - rustc.git/blame - src/test/ui/extern/extern-types-unsized.stderr
New upstream version 1.65.0+dfsg1
[rustc.git] / src / test / ui / extern / extern-types-unsized.stderr
CommitLineData
b7449926 1error[E0277]: the size for values of type `A` cannot be known at compilation time
e1599b0c 2 --> $DIR/extern-types-unsized.rs:22:20
b7449926
XL
3 |
4LL | assert_sized::<A>();
e1599b0c 5 | ^ doesn't have a size known at compile-time
b7449926 6 |
1b1a35ee 7 = help: the trait `Sized` is not implemented for `A`
94222f64
XL
8note: required by a bound in `assert_sized`
9 --> $DIR/extern-types-unsized.rs:19:17
10 |
11LL | fn assert_sized<T>() {}
12 | ^ required by this bound in `assert_sized`
ba9703b0
XL
13help: consider relaxing the implicit `Sized` restriction
14 |
5869c6ff 15LL | fn assert_sized<T: ?Sized>() {}
94222f64 16 | ++++++++
b7449926
XL
17
18error[E0277]: the size for values of type `A` cannot be known at compilation time
f2b60f7d 19 --> $DIR/extern-types-unsized.rs:25:20
b7449926
XL
20 |
21LL | assert_sized::<Foo>();
f2b60f7d 22 | ^^^ doesn't have a size known at compile-time
b7449926 23 |
1b1a35ee 24 = help: within `Foo`, the trait `Sized` is not implemented for `A`
cdc7bbd5
XL
25note: required because it appears within the type `Foo`
26 --> $DIR/extern-types-unsized.rs:9:8
27 |
28LL | struct Foo {
29 | ^^^
94222f64
XL
30note: required by a bound in `assert_sized`
31 --> $DIR/extern-types-unsized.rs:19:17
32 |
33LL | fn assert_sized<T>() {}
34 | ^ required by this bound in `assert_sized`
f035d41b
XL
35help: consider relaxing the implicit `Sized` restriction
36 |
5869c6ff 37LL | fn assert_sized<T: ?Sized>() {}
94222f64 38 | ++++++++
b7449926
XL
39
40error[E0277]: the size for values of type `A` cannot be known at compilation time
f2b60f7d 41 --> $DIR/extern-types-unsized.rs:28:20
b7449926
XL
42 |
43LL | assert_sized::<Bar<A>>();
f2b60f7d 44 | ^^^^^^ doesn't have a size known at compile-time
b7449926 45 |
1b1a35ee 46 = help: within `Bar<A>`, the trait `Sized` is not implemented for `A`
cdc7bbd5
XL
47note: required because it appears within the type `Bar<A>`
48 --> $DIR/extern-types-unsized.rs:14:8
49 |
50LL | struct Bar<T: ?Sized> {
51 | ^^^
94222f64
XL
52note: required by a bound in `assert_sized`
53 --> $DIR/extern-types-unsized.rs:19:17
54 |
55LL | fn assert_sized<T>() {}
56 | ^ required by this bound in `assert_sized`
f035d41b
XL
57help: consider relaxing the implicit `Sized` restriction
58 |
5869c6ff 59LL | fn assert_sized<T: ?Sized>() {}
94222f64 60 | ++++++++
b7449926
XL
61
62error[E0277]: the size for values of type `A` cannot be known at compilation time
f2b60f7d 63 --> $DIR/extern-types-unsized.rs:31:20
b7449926
XL
64 |
65LL | assert_sized::<Bar<Bar<A>>>();
f2b60f7d 66 | ^^^^^^^^^^^ doesn't have a size known at compile-time
b7449926 67 |
1b1a35ee 68 = help: within `Bar<Bar<A>>`, the trait `Sized` is not implemented for `A`
cdc7bbd5
XL
69note: required because it appears within the type `Bar<A>`
70 --> $DIR/extern-types-unsized.rs:14:8
71 |
72LL | struct Bar<T: ?Sized> {
73 | ^^^
94222f64
XL
74note: required by a bound in `assert_sized`
75 --> $DIR/extern-types-unsized.rs:19:17
76 |
77LL | fn assert_sized<T>() {}
78 | ^ required by this bound in `assert_sized`
f035d41b
XL
79help: consider relaxing the implicit `Sized` restriction
80 |
5869c6ff 81LL | fn assert_sized<T: ?Sized>() {}
94222f64 82 | ++++++++
b7449926
XL
83
84error: aborting due to 4 previous errors
85
86For more information about this error, try `rustc --explain E0277`.