Unify const-checking structured errors for &mut and &raw mut#77420
Merged
bors merged 2 commits intorust-lang:masterfrom Oct 22, 2020
Merged
Unify const-checking structured errors for &mut and &raw mut#77420bors merged 2 commits intorust-lang:masterfrom
&mut and &raw mut#77420bors merged 2 commits intorust-lang:masterfrom
Conversation
Contributor
|
r? @davidtwco (rust_highfive has picked a reviewer for you, use r? to override) |
f64ec95 to
c1494d6
Compare
davidtwco
reviewed
Oct 2, 2020
| #![feature(raw_ref_op)] | ||
|
|
||
| const A: () = { let mut x = 2; &raw mut x; }; //~ ERROR `&raw mut` is not allowed | ||
| const A: () = { let mut x = 2; &raw mut x; }; //~ mutable reference |
Member
There was a problem hiding this comment.
Should this test's annotations still have ERROR in them?
Suggested change
| const A: () = { let mut x = 2; &raw mut x; }; //~ mutable reference | |
| const A: () = { let mut x = 2; &raw mut x; }; //~ ERROR mutable reference |
Member
There was a problem hiding this comment.
I was under the impression that it was required for the annotation.
There was a problem hiding this comment.
it's good to have but not a necessity iirc.
davidtwco
approved these changes
Oct 2, 2020
Member
davidtwco
left a comment
There was a problem hiding this comment.
LGTM, r=me after resolving previous comment
|
@bors r=davidtwco |
Collaborator
|
📌 Commit c1494d6 has been approved by |
bors
added a commit
to rust-lang-ci/rust
that referenced
this pull request
Oct 22, 2020
Rollup of 10 pull requests Successful merges: - rust-lang#77420 (Unify const-checking structured errors for `&mut` and `&raw mut`) - rust-lang#77554 (Support signed integers and `char` in v0 mangling) - rust-lang#77976 (Mark inout asm! operands as used in liveness pass) - rust-lang#78009 (Haiku: explicitly set CMAKE_SYSTEM_NAME when cross-compiling) - rust-lang#78084 (Greatly improve display for small mobile devices screens) - rust-lang#78155 (Fix two small issues in compiler/rustc_lint/src/types.rs) - rust-lang#78156 (Fixed build failure of `rustfmt`) - rust-lang#78172 (Add test case for rust-lang#77062) - rust-lang#78188 (Add tracking issue number for pin_static_ref) - rust-lang#78200 (Add `ControlFlow::is_{break,continue}` methods) Failed merges: r? `@ghost`
This file contains hidden or 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
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.
Resolves #77414 as well as a FIXME.