-
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
Rollup of 7 pull requests #65671
Rollup of 7 pull requests #65671
Conversation
Union fields may now never have a type with attached destructor. This for example allows unions to use arbitrary field types only by wrapping them in ManuallyDrop. The stable rule remains, that union fields must be Copy. We use the new rule for the `untagged_union` feature. See RFC 2514. Note for ui tests: We can't test move out through Box's deref-move since we can't have a Box in a union anymore.
Cases where it would trigger are now hard errors.
Co-Authored-By: Mazdak Farrokhzad <[email protected]>
Co-Authored-By: Mazdak Farrokhzad <[email protected]>
Co-Authored-By: Mazdak Farrokhzad <[email protected]>
Co-Authored-By: Mazdak Farrokhzad <[email protected]>
make is_power_of_two a const function This makes `is_power_of_two` a const function by using `&` instead of short-circuiting `&&`; Rust supports bitwise `&` for `bool` and short-circuiting is not required in the existing expression. I don't think this needs a const-hack label as I don't find the changed code less readable, if anything I prefer that it is clearer that short circuiting is not used. @oli-obk
miri: add write_bytes method to Memory doing bounds-checks and supporting iterators This lets us avoid some direct `Allocation` accesses in Miri.
…r=Centril Remove unnecessary trait bounds and derivations This PR removes unnecessary trait bounds and derivations from many types. r? @nikomatsakis
…um,Centril keep the root dir clean from debugging We landed this before with rust-lang#63307 but recently in rust-lang#65630 the IMO bad ignore crept back in. If you regularly do graphviz-based debugging and you are fine leaving junk in the rustc root dir, please configure your local `.git/info/exclude`. But most people working on rustc don't work with graphciz all that often (I for once never did), and not everyone likes to have stray generated files in their source dirs. Also Cc rust-lang#63373 rust-lang#53768 @ecstatic-morse @Mark-Simulacrum
…st, r=eddyb Rename `ConstValue::Infer(InferConst::Canonical(..))` to `ConstValue::Bound(..)` It already has the right form, so this is just a renaming. Fixes rust-lang#65655. r? @eddyb
@bors r+ p=7 rollup=never |
📌 Commit 56756c2 has been approved by |
⌛ Testing commit 56756c2 with merge 64c3b419733536b48e5f1100cba44bdad4700303... |
💥 Test timed out |
@bors retry |
Rollup of 7 pull requests Successful merges: - #62330 (Change untagged_unions to not allow union fields with drop) - #65092 (make is_power_of_two a const function) - #65621 (miri: add write_bytes method to Memory doing bounds-checks and supporting iterators) - #65647 (Remove unnecessary trait bounds and derivations) - #65653 (keep the root dir clean from debugging) - #65660 (Rename `ConstValue::Infer(InferConst::Canonical(..))` to `ConstValue::Bound(..)`) - #65663 (Fix typo from #65214) Failed merges: r? @ghost
☀️ Test successful - checks-azure |
📣 Toolstate changed by #65671! Tested on commit 6576f4b. 💔 clippy-driver on windows: test-pass → build-fail (cc @mcarton @oli-obk @Manishearth @flip1995 @yaahc @phansch @llogiq, @rust-lang/infra). |
Tested on commit rust-lang/rust@6576f4b. Direct link to PR: <rust-lang/rust#65671> 💔 clippy-driver on windows: test-pass → build-fail (cc @mcarton @oli-obk @Manishearth @flip1995 @yaahc @phansch @llogiq, @rust-lang/infra). 💔 clippy-driver on linux: test-pass → build-fail (cc @mcarton @oli-obk @Manishearth @flip1995 @yaahc @phansch @llogiq, @rust-lang/infra). 💔 miri on windows: test-pass → build-fail (cc @oli-obk @eddyb @RalfJung, @rust-lang/infra). 💔 miri on linux: test-pass → build-fail (cc @oli-obk @eddyb @RalfJung, @rust-lang/infra).
Successful merges:
ConstValue::Infer(InferConst::Canonical(..))
toConstValue::Bound(..)
#65660 (RenameConstValue::Infer(InferConst::Canonical(..))
toConstValue::Bound(..)
)Failed merges:
r? @ghost