-
Notifications
You must be signed in to change notification settings - Fork 12.7k
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 11 pull requests #86457
Closed
Closed
Rollup of 11 pull requests #86457
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
I find this more consistent with RefCell's equivalent method.
… r=m-ou-se Stabilize span_open() and span_close(). This proposes to stabilize `Group::span_open()` and `Group::span_close()`. These are part of the `proc_macro_span` feature gate tracked in rust-lang#54725 Most of the features gated behind `proc_macro_span` are about source location information (file path, line and column information), expansion information (parent()), source_text(), etc. Those are not ready for stabilizaiton. However, getting the span of the `(` and `)` separately instead of only of the entire `(...)` can be very useful in proc macros, and doesn't seem blocked on anything that all the other parts of `proc_macro_span` are blocked on. So, this renames the feature gate for those two functions to `proc_macro_group_span` and stabilizes them.
…hnTitor Use as_secs_f64 in JunitFormatter cc ``@andoriyu``
…d-versions-layout, r=GuillaumeGomez Fix rustdoc stabilized versions layout Fixes rust-lang#86342 r? ``@GuillaumeGomez``
…rtichaut Add pattern walking support to THIR walker Suggested in rust-lang#85263 (comment), this splits off the support for pattern walking in THIR from rust-lang#85263. This has no observable effect on THIR unsafety checking, since it is not currently possible to trigger unsafety from the THIR checker using the additional patterns or constants that are now walked. THIR patterns are walked in source code order. r? `@LeSeulArtichaut`
Alter std::cell::Cell::get_mut documentation I felt that there was some inconsistency between between Cell and RefCell with regards to their `get_mut` method documentation: `RefCell` flags this method as "unusual" in that it takes `&mut self`, while `Cell` does not. I attempted to flag this in `Cell`s documentation as well, and point to `RefCell`s method in the case where it is required. Find relevant parts of docs and the new version below. The current docs for `Cell::get_mut`: > Returns a mutable reference to the underlying data. This call borrows Cell mutably (at compile-time) which guarantees that we possess the only reference. And `RefCell::get_mut`: > Returns a mutable reference to the underlying data. This call borrows `RefCell` mutably (at compile-time) so there is no need for dynamic checks. However be cautious: this method expects self to be mutable, which is generally not the case when using a `RefCell`. Take a look at the `borrow_mut` method instead if self isn’t mutable. Also, please be aware that this method is only for special circumstances and is usually not what you want. In case of doubt, use `borrow_mut` instead. My attempt to make `Cell::get_mut` clearer: > Returns a mutable reference to the underlying data. This call borrows `Cell` mutably (at compile-time) which guaranteesthat we possess the only reference. However be cautious: this method expects `self` to be mutable, which is generally not the case when using a `Cell`. If you require interior mutability by reference, consider using `RefCell` which provides run-time checked mutable borrows through its `borrow_mut` method.
Use `map_or` instead of open-coding it ``@rustbot`` modify labels +C-cleanup +T-compiler
…=Aaron1011 Lint for unused borrows as part of UNUSED_MUST_USE close rust-lang#76264 base on rust-lang#76894 r? `@RalfJung`
add various coments to explain how the TAIT code works r? `@oli-obk`
…r=m-ou-se Update library tracking issue for libs-api rename.
…tichaut Fix ICE with `#[repr(simd)]` on enum This pull request fixes rust-lang#83505. `#[repr(simd)]` may only be applied to structs, which correctly causes `E0517` for the example given in rust-lang#83505, but the compiler attempts to recover from this error, which leads to an ICE later, when `.non_enum_variant()` is called on the `AdtDef`. I have added a check that prevents this from happening.
stdlib: Fix typo in internal RefCell docs `BorroeError` => `BorrowError` in [cell.rs](https://github.com/rust-lang/rust/blob/master/library/core/src/cell.rs#L581)
@bors r+ rollup=never p=5 |
📌 Commit 5f90563 has been approved by |
bors
added
the
S-waiting-on-bors
Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
label
Jun 19, 2021
⌛ Testing commit 5f90563 with merge 323527697ee8d85ea76e03e01c2684cda03325cc... |
This contains merged PRs, @bors retry r- |
bors
added
S-waiting-on-author
Status: This is awaiting some action (such as code changes or more information) from the author.
and removed
S-waiting-on-bors
Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
labels
Jun 19, 2021
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
rollup
A PR which is a rollup
S-waiting-on-author
Status: This is awaiting some action (such as code changes or more information) from the author.
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.
Successful merges:
map_or
instead of open-coding it #86407 (Usemap_or
instead of open-coding it)#[repr(simd)]
on enum #86444 (Fix ICE with#[repr(simd)]
on enum)Failed merges:
r? @ghost
@rustbot modify labels: rollup
Create a similar rollup