-
Notifications
You must be signed in to change notification settings - Fork 12.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow static mut definitions with #[linkage] #125920
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Unlike static declarations with #[linkage], for definitions rustc doesn't rewrite it to add an extra indirection.
rustbot
added
S-waiting-on-review
Status: Awaiting review from the assignee but also interested parties.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
labels
Jun 3, 2024
Urgau
approved these changes
Jun 3, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Makes sense to me.
Feel free to r=me unless to you want someone more familiar with this part of rustc.
@bors r=Urgau |
bors
added
S-waiting-on-bors
Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
and removed
S-waiting-on-review
Status: Awaiting review from the assignee but also interested parties.
labels
Jun 3, 2024
fmease
added a commit
to fmease/rust
that referenced
this pull request
Jun 4, 2024
…f, r=Urgau Allow static mut definitions with #[linkage] Unlike static declarations with #[linkage], for definitions rustc doesn't rewrite it to add an extra indirection. This was accidentally disallowed in rust-lang#125046. cc rust-lang#125800 (comment)
bors
added a commit
to rust-lang-ci/rust
that referenced
this pull request
Jun 5, 2024
Rollup of 7 pull requests Successful merges: - rust-lang#125273 (bootstrap: implement new feature `bootstrap-self-test`) - rust-lang#125800 (Fix `mut` static task queue in SGX target) - rust-lang#125903 (rustc_span: Inline some hot functions) - rust-lang#125920 (Allow static mut definitions with #[linkage]) - rust-lang#125921 (coverage: Carve out hole spans in a separate early pass) - rust-lang#125995 (Use inline const blocks to create arrays of `MaybeUninit`.) - rust-lang#125996 (Closures are recursively reachable) r? `@ghost` `@rustbot` modify labels: rollup
@bors rollup |
bors
added a commit
to rust-lang-ci/rust
that referenced
this pull request
Jun 5, 2024
…kingjubilee Rollup of 12 pull requests Successful merges: - rust-lang#123168 (Add `size_of` and `size_of_val` and `align_of` and `align_of_val` to the prelude) - rust-lang#125273 (bootstrap: implement new feature `bootstrap-self-test`) - rust-lang#125683 (Rewrite `suspicious-library`, `resolve-rename` and `incr-prev-body-beyond-eof` `run-make` tests in `rmake.rs` format) - rust-lang#125815 (`rustc_parse` top-level cleanups) - rust-lang#125903 (rustc_span: Inline some hot functions) - rust-lang#125906 (Remove a bunch of redundant args from `report_method_error`) - rust-lang#125920 (Allow static mut definitions with #[linkage]) - rust-lang#125982 (Make deleting on LinkedList aware of the allocator) - rust-lang#125995 (Use inline const blocks to create arrays of `MaybeUninit`.) - rust-lang#125996 (Closures are recursively reachable) - rust-lang#126003 (Add a co-maintainer for the two ARMv4T targets) - rust-lang#126004 (Add another test for hidden types capturing lifetimes that outlive but arent mentioned in substs) r? `@ghost` `@rustbot` modify labels: rollup
rust-timer
added a commit
to rust-lang-ci/rust
that referenced
this pull request
Jun 5, 2024
Rollup merge of rust-lang#125920 - bjorn3:allow_static_mut_linkage_def, r=Urgau Allow static mut definitions with #[linkage] Unlike static declarations with #[linkage], for definitions rustc doesn't rewrite it to add an extra indirection. This was accidentally disallowed in rust-lang#125046. cc rust-lang#125800 (comment)
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
S-waiting-on-bors
Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Unlike static declarations with #[linkage], for definitions rustc doesn't rewrite it to add an extra indirection.
This was accidentally disallowed in #125046.
cc #125800 (comment)