You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on May 28, 2025. It is now read-only.
Rollup merge of rust-lang#130394 - RalfJung:mut-ref-to-immut, r=saethlin
const: don't ICE when encountering a mutable ref to immutable memory
Turns out that this can actually happen -- thanks to `@matthiaskrgr` for producing a testcase. :)
Fixesrust-lang#130392
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ constructing invalid value: encountered mutable reference or box pointing to read-only memory
32
+
|
33
+
= 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.
34
+
= note: the raw bytes of the constant (size: $SIZE, align: $ALIGN) {
35
+
HEX_DUMP
36
+
}
37
+
27
38
error[E0716]: temporary value dropped while borrowed
0 commit comments