-
Notifications
You must be signed in to change notification settings - Fork 13.4k
cannot mutate statics in initalizer of another static #56903
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Labels
P-high
High priority
regression-from-stable-to-beta
Performance or correctness regression from stable to beta.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
Comments
cc @tarcieri Repro static mut STDERR_BUFFER_SPACE: [u8; 42] = [0u8; 42];
pub static mut STDERR_BUFFER: *mut [u8] = unsafe { &mut STDERR_BUFFER_SPACE }; I'm going to fix the regression, but I just want to note that https://github.com/oxidizers/drdns/blob/98c1153a09642c2a5d8d2ed77ef7d9429d94995a/src/buffer.rs#L292 is very dangerous to use. This looks like another argument for #53639 |
FWIW the code in question is some mechanically translated C with the translation performed by |
pietroalbini
added a commit
to pietroalbini/rust
that referenced
this issue
Dec 20, 2018
… r=davidtwco Fix a recently introduced regression fixes rust-lang#56903
triage: P-high. |
Centril
added a commit
to Centril/rust
that referenced
this issue
Dec 22, 2018
… r=davidtwco Fix mutable references in `static mut` fixes rust-lang#56903
Centril
added a commit
to Centril/rust
that referenced
this issue
Dec 23, 2018
… r=davidtwco Fix mutable references in `static mut` fixes rust-lang#56903
Centril
added a commit
to Centril/rust
that referenced
this issue
Dec 23, 2018
… r=davidtwco Fix mutable references in `static mut` fixes rust-lang#56903
Centril
added a commit
to Centril/rust
that referenced
this issue
Dec 23, 2018
… r=davidtwco Fix mutable references in `static mut` fixes rust-lang#56903
# for free
to join this conversation on GitHub.
Already have an account?
# to comment
Labels
P-high
High priority
regression-from-stable-to-beta
Performance or correctness regression from stable to beta.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
https://crater-reports.s3.amazonaws.com/beta-1.32-1/beta-2018-12-05/gh/oxidizers.drdns/log.txt
The text was updated successfully, but these errors were encountered: