mirror of
https://github.com/rust-lang/rust.git
synced 2025-10-02 10:18:25 +00:00

a more general version of https://github.com/rust-lang/rust/pull/146080. after a bit of hacking in [`fluent.rs`](https://github.com/rust-lang/rust/blob/master/compiler/rustc_fluent_macro/src/fluent.rs), i discovered that i'm not the only one that is bad at following guidelines 😅. this pr lowercases the first letter of all the error messages in the codebase. (i did not change things that are traditionally uppercased such as _MIR_, _ABI_ or _C_) i think it's reasonable to run a `@bors try` so all the test suite is checked, as i cannot run some of the tests on my machine. i double checked (and replaced manually) all the old error messages, but better be safe than sorry. in the future i will try to add a check in `x test tidy` that errors if an error message starts with an uppercase letter.
70 lines
4.1 KiB
Plaintext
70 lines
4.1 KiB
Plaintext
error[E0080]: constructing invalid value: encountered ALLOC1<imm>, but expected a vtable pointer
|
|
--> $DIR/ub-incorrect-vtable.rs:18:1
|
|
|
|
|
LL | const INVALID_VTABLE_ALIGNMENT: &dyn Trait =
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ it is undefined behavior to use this value
|
|
|
|
|
= note: the rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rustc repository if you believe it should not be considered undefined behavior.
|
|
= note: the raw bytes of the constant (size: 16, align: 8) {
|
|
╾ALLOC0<imm>╼ ╾ALLOC1<imm>╼ │ ╾──────╼╾──────╼
|
|
}
|
|
|
|
error[E0080]: constructing invalid value: encountered ALLOC3<imm>, but expected a vtable pointer
|
|
--> $DIR/ub-incorrect-vtable.rs:22:1
|
|
|
|
|
LL | const INVALID_VTABLE_SIZE: &dyn Trait =
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ it is undefined behavior to use this value
|
|
|
|
|
= note: the rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rustc repository if you believe it should not be considered undefined behavior.
|
|
= note: the raw bytes of the constant (size: 16, align: 8) {
|
|
╾ALLOC2<imm>╼ ╾ALLOC3<imm>╼ │ ╾──────╼╾──────╼
|
|
}
|
|
|
|
error[E0080]: constructing invalid value at .0: encountered ALLOC5<imm>, but expected a vtable pointer
|
|
--> $DIR/ub-incorrect-vtable.rs:31:1
|
|
|
|
|
LL | const INVALID_VTABLE_ALIGNMENT_UB: W<&dyn Trait> =
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ it is undefined behavior to use this value
|
|
|
|
|
= note: the rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rustc repository if you believe it should not be considered undefined behavior.
|
|
= note: the raw bytes of the constant (size: 16, align: 8) {
|
|
╾ALLOC4<imm>╼ ╾ALLOC5<imm>╼ │ ╾──────╼╾──────╼
|
|
}
|
|
|
|
error[E0080]: constructing invalid value at .0: encountered ALLOC7<imm>, but expected a vtable pointer
|
|
--> $DIR/ub-incorrect-vtable.rs:35:1
|
|
|
|
|
LL | const INVALID_VTABLE_SIZE_UB: W<&dyn Trait> =
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ it is undefined behavior to use this value
|
|
|
|
|
= note: the rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rustc repository if you believe it should not be considered undefined behavior.
|
|
= note: the raw bytes of the constant (size: 16, align: 8) {
|
|
╾ALLOC6<imm>╼ ╾ALLOC7<imm>╼ │ ╾──────╼╾──────╼
|
|
}
|
|
|
|
error[E0080]: constructing invalid value at .0: encountered ALLOC9<imm>, but expected a vtable pointer
|
|
--> $DIR/ub-incorrect-vtable.rs:40:1
|
|
|
|
|
LL | const INVALID_VTABLE_UB: W<&dyn Trait> =
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ it is undefined behavior to use this value
|
|
|
|
|
= note: the rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rustc repository if you believe it should not be considered undefined behavior.
|
|
= note: the raw bytes of the constant (size: 16, align: 8) {
|
|
╾ALLOC8<imm>╼ ╾ALLOC9<imm>╼ │ ╾──────╼╾──────╼
|
|
}
|
|
|
|
error[E0080]: constructing invalid value at .1: encountered a dangling reference (going beyond the bounds of its allocation)
|
|
--> $DIR/ub-incorrect-vtable.rs:86:1
|
|
|
|
|
LL | const G: Wide = unsafe { Transmute { t: FOO }.u };
|
|
| ^^^^^^^^^^^^^ it is undefined behavior to use this value
|
|
|
|
|
= note: the rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rustc repository if you believe it should not be considered undefined behavior.
|
|
= note: the raw bytes of the constant (size: 16, align: 8) {
|
|
╾ALLOC10<imm>╼ ╾ALLOC11╼ │ ╾──────╼╾──────╼
|
|
}
|
|
|
|
error: aborting due to 6 previous errors
|
|
|
|
For more information about this error, try `rustc --explain E0080`.
|