fork/rust

git clone https://git.julia.blue/fork/rust

borsAuto merge of #66089 - Mark-Simulacrum:stable-next, r=Mark-Simulacrum4560ea788cb

1.39.0
3.2 KiB67 linesraw
1error[E0277]: the size for values of type `X` cannot be known at compilation time
2  --> $DIR/unsized5.rs:4:5
3   |
4LL |     f1: X,
5   |     ^^^^^ doesn't have a size known at compile-time
6   |
7   = help: the trait `std::marker::Sized` is not implemented for `X`
8   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
9   = help: consider adding a `where X: std::marker::Sized` bound
10   = note: only the last field of a struct may have a dynamically sized type
11
12error[E0277]: the size for values of type `X` cannot be known at compilation time
13  --> $DIR/unsized5.rs:10:5
14   |
15LL |     g: X,
16   |     ^^^^ doesn't have a size known at compile-time
17   |
18   = help: the trait `std::marker::Sized` is not implemented for `X`
19   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
20   = help: consider adding a `where X: std::marker::Sized` bound
21   = note: only the last field of a struct may have a dynamically sized type
22
23error[E0277]: the size for values of type `str` cannot be known at compilation time
24  --> $DIR/unsized5.rs:15:5
25   |
26LL |     f: str,
27   |     ^^^^^^ doesn't have a size known at compile-time
28   |
29   = help: the trait `std::marker::Sized` is not implemented for `str`
30   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
31   = note: only the last field of a struct may have a dynamically sized type
32
33error[E0277]: the size for values of type `[u8]` cannot be known at compilation time
34  --> $DIR/unsized5.rs:20:5
35   |
36LL |     f: [u8],
37   |     ^^^^^^^ doesn't have a size known at compile-time
38   |
39   = help: the trait `std::marker::Sized` is not implemented for `[u8]`
40   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
41   = note: only the last field of a struct may have a dynamically sized type
42
43error[E0277]: the size for values of type `X` cannot be known at compilation time
44  --> $DIR/unsized5.rs:25:8
45   |
46LL |     V1(X, isize),
47   |        ^ doesn't have a size known at compile-time
48   |
49   = help: the trait `std::marker::Sized` is not implemented for `X`
50   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
51   = help: consider adding a `where X: std::marker::Sized` bound
52   = note: no field of an enum variant may have a dynamically sized type
53
54error[E0277]: the size for values of type `X` cannot be known at compilation time
55  --> $DIR/unsized5.rs:29:8
56   |
57LL |     V2{f1: X, f: isize},
58   |        ^^^^^ doesn't have a size known at compile-time
59   |
60   = help: the trait `std::marker::Sized` is not implemented for `X`
61   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
62   = help: consider adding a `where X: std::marker::Sized` bound
63   = note: no field of an enum variant may have a dynamically sized type
64
65error: aborting due to 6 previous errors
66
67For more information about this error, try `rustc --explain E0277`.