@@ -7,29 +7,65 @@ LL | const CONST_0: dyn Debug + Sync = *(&0 as &(dyn Debug + Sync));
7
7
= help: the trait `Sized` is not implemented for `(dyn Debug + Sync + 'static)`
8
8
9
9
error[E0277]: the size for values of type `str` cannot be known at compilation time
10
- --> $DIR/const-unsized.rs:6 :18
10
+ --> $DIR/const-unsized.rs:7 :18
11
11
|
12
12
LL | const CONST_FOO: str = *"foo";
13
13
| ^^^ doesn't have a size known at compile-time
14
14
|
15
15
= help: the trait `Sized` is not implemented for `str`
16
16
17
17
error[E0277]: the size for values of type `(dyn Debug + Sync + 'static)` cannot be known at compilation time
18
- --> $DIR/const-unsized.rs:9 :18
18
+ --> $DIR/const-unsized.rs:11 :18
19
19
|
20
20
LL | static STATIC_1: dyn Debug + Sync = *(&1 as &(dyn Debug + Sync));
21
21
| ^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
22
22
|
23
23
= help: the trait `Sized` is not implemented for `(dyn Debug + Sync + 'static)`
24
24
25
25
error[E0277]: the size for values of type `str` cannot be known at compilation time
26
- --> $DIR/const-unsized.rs:12 :20
26
+ --> $DIR/const-unsized.rs:15 :20
27
27
|
28
28
LL | static STATIC_BAR: str = *"bar";
29
29
| ^^^ doesn't have a size known at compile-time
30
30
|
31
31
= help: the trait `Sized` is not implemented for `str`
32
32
33
- error: aborting due to 4 previous errors
33
+ error[E0277]: the size for values of type `(dyn Debug + Sync + 'static)` cannot be known at compilation time
34
+ --> $DIR/const-unsized.rs:3:35
35
+ |
36
+ LL | const CONST_0: dyn Debug + Sync = *(&0 as &(dyn Debug + Sync));
37
+ | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
38
+ |
39
+ = help: the trait `Sized` is not implemented for `(dyn Debug + Sync + 'static)`
40
+ = note: constant expressions must have a statically known size
41
+
42
+ error[E0277]: the size for values of type `str` cannot be known at compilation time
43
+ --> $DIR/const-unsized.rs:7:24
44
+ |
45
+ LL | const CONST_FOO: str = *"foo";
46
+ | ^^^^^^ doesn't have a size known at compile-time
47
+ |
48
+ = help: the trait `Sized` is not implemented for `str`
49
+ = note: constant expressions must have a statically known size
50
+
51
+ error[E0277]: the size for values of type `(dyn Debug + Sync + 'static)` cannot be known at compilation time
52
+ --> $DIR/const-unsized.rs:11:37
53
+ |
54
+ LL | static STATIC_1: dyn Debug + Sync = *(&1 as &(dyn Debug + Sync));
55
+ | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
56
+ |
57
+ = help: the trait `Sized` is not implemented for `(dyn Debug + Sync + 'static)`
58
+ = note: constant expressions must have a statically known size
59
+
60
+ error[E0277]: the size for values of type `str` cannot be known at compilation time
61
+ --> $DIR/const-unsized.rs:15:26
62
+ |
63
+ LL | static STATIC_BAR: str = *"bar";
64
+ | ^^^^^^ doesn't have a size known at compile-time
65
+ |
66
+ = help: the trait `Sized` is not implemented for `str`
67
+ = note: constant expressions must have a statically known size
68
+
69
+ error: aborting due to 8 previous errors
34
70
35
71
For more information about this error, try `rustc --explain E0277`.
0 commit comments