2025-01-02 18:18:19 +00:00
|
|
|
error[E0308]: mismatched types
|
|
|
|
--> $DIR/issue-104768.rs:1:15
|
|
|
|
|
|
|
|
|
LL | const A: &_ = 0_u32;
|
|
|
|
| ^^^^^ expected `&_`, found `u32`
|
|
|
|
|
|
|
|
|
= note: expected reference `&'static _`
|
|
|
|
found type `u32`
|
|
|
|
help: consider borrowing here
|
|
|
|
|
|
|
|
|
LL | const A: &_ = &0_u32;
|
|
|
|
| +
|
|
|
|
|
2022-11-24 11:12:34 +00:00
|
|
|
error[E0121]: the placeholder `_` is not allowed within types on item signatures for constants
|
2025-01-02 18:25:52 +00:00
|
|
|
--> $DIR/issue-104768.rs:1:11
|
2022-11-24 11:12:34 +00:00
|
|
|
|
|
|
|
|
LL | const A: &_ = 0_u32;
|
2025-01-02 22:19:45 +00:00
|
|
|
| ^ not allowed in type signatures
|
|
|
|
|
|
|
|
|
help: replace this with a fully-specified type
|
|
|
|
|
|
|
|
|
LL | const A: u32 = 0_u32;
|
|
|
|
| ~~~
|
2022-11-24 11:12:34 +00:00
|
|
|
|
2025-01-02 18:18:19 +00:00
|
|
|
error: aborting due to 2 previous errors
|
2022-11-24 11:12:34 +00:00
|
|
|
|
2025-01-02 18:18:19 +00:00
|
|
|
Some errors have detailed explanations: E0121, E0308.
|
|
|
|
For more information about an error, try `rustc --explain E0121`.
|