-
Notifications
You must be signed in to change notification settings - Fork 12.9k
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 mutable slices in mutable static items #12742
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
This is a follow-up patch that moves the mut slice check to the recently added `check_static` Closes rust-lang#11411
That said, I'm not opposed to land this, and adding this issue to the RFC that I ought to write. Eventually we may want to straighten it out but in the meantime it affords the ability to have mut slices in static muts at least. |
bors
added a commit
to rust-lang-ci/rust
that referenced
this pull request
Jul 25, 2022
…-keys, r=Veykril Fix obsolete config keys The config keys were drastically reorganized by rust-lang#12010, but the docs don't reflect the updates, causing inconsistency and confusion. I checked for such obsolete configuration keys and updated to the new one. For reproducibility, I attach a small shell script that I used to examine the old keys. Now the script only detects `cargoExtraArgs` and `overrideCargo`, which originates from other type definition in the code but not from the configuration. <details><summary>script</summary> ```bash echo "allowMergingIntoGlobImports exprFillDefault importEnforceGranularity importGranularity importMergeBehavior importMergeBehaviour importGroup importPrefix warmup loadOutDirsFromCheck runBuildScripts runBuildScriptsCommand useRustcWrapperForBuildScripts enableExperimental procAttrMacros breakPoints exitPoints yieldPoints linksInHover linksInHover gotoTypeDef chainingHints closureReturnTypeHints hideNamedConstructorHints parameterHints reborrowHints typeHints lruCapacity cargoExtraArgs overrideCargo rustcSource enableRangeFormatting assist\.allowMergingIntoGlobImports assist\.exprFillDefault assist\.importEnforceGranularity assist\.importGranularity assist\.importMergeBehavior assist\.importMergeBehaviour assist\.importGroup assist\.importPrefix primeCaches\.enable cache\.warmup cargo\.loadOutDirsFromCheck cargo\.runBuildScripts cargo\.runBuildScriptsCommand cargo\.useRustcWrapperForBuildScripts completion\.snippets diagnostics\.enableExperimental experimental\.procAttrMacros highlighting\.strings highlightRelated\.breakPoints highlightRelated\.exitPoints highlightRelated\.yieldPoints highlightRelated\.references hover\.documentation hover\.linksInHover hoverActions\.linksInHover hoverActions\.debug hoverActions\.enable hoverActions\.gotoTypeDef hoverActions\.implementations hoverActions\.references hoverActions\.run inlayHints\.chainingHints inlayHints\.closureReturnTypeHints inlayHints\.hideNamedConstructorHints inlayHints\.parameterHints inlayHints\.reborrowHints inlayHints\.typeHints lruCapacity runnables\.cargoExtraArgs runnables\.overrideCargo rustcSource rustfmt\.enableRangeFormatting allFeatures addCallArgumentSnippets addCallParenthesis callInfo\.full cargo\.allFeatures checkOnSave\.allFeatures completion\.addCallArgumentSnippets completion\.addCallParenthesis" | while read -r pattern do rg '\b'$pattern'\b([^.]|$)' . -g "!crates/rust-analyzer/src/config/patch_old_style.rs" -g "!editors/code/src/config.ts" -g "!a.sh" --no-heading --color=always --line-number done exit excluded # debug # enable # run # implementations # references # documentation # references # snippets # strings # full ``` </details>
xFrednet
pushed a commit
to xFrednet/rust
that referenced
this pull request
May 5, 2024
…e-init, r=dswij Don't lint assigning_clones on nested late init locals Fixes rust-lang#12741 changelog: none
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
This PR enables the use of mutable slices in mutable static items. The work was started by @xales and I added a follow-up commit that moves the immutable restriction to the recently added
check_static
Closes #11411