-
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 5 pull requests #90224
Closed
Closed
Rollup of 5 pull requests #90224
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 fixes warning when building Rust and running tests: ``` warning: library kind `static-nobundle` has been superseded by specifying `-bundle` on library kind `static`. Try `static:-bundle` warning: `rustc_llvm` (lib) generated 2 warnings (1 duplicate) ```
The makes the heading / documentation distinction clearer.
Normalize MIR with RevealAll before optimizations. Fixes rust-lang#78442
Add rustc lint, warning when iterating over hashmaps r? rust-lang/wg-incr-comp
…mez,camelid Fix alignment of method headings for scannability We sometimes use indentation to indicate something is a heading: The section that comes after is indented by 24px relative to the heading. However, the relationship between the "Implementations" section heading, the `impl` headings it contains, and the `pub fn` subheadings within each impl, is awkward. It goes **Implementations**, 15px indent, `impl`, 5px indent, `pub fn`, 4px indent, docblock. I line up `impl` and `pub fn` with the `Implementations` heading, give `impl` a larger font size to indicate it is higher in the hierarchy, and indent the docblock a full 24px relative to their parent, matching the indents we use elsewhere to distinguish section headings. By letting the `pub fn` stick out to the left of the docblock, I think this makes methods significantly more scannable. Related to rust-lang#59829 r? ``@camelid`` [Old](https://doc.rust-lang.org/nightly/std/string/struct.String.html#implementations): [![image](https://user-images.githubusercontent.com/220205/138380233-9c63a0f2-0f80-40a3-ab3d-a1ee9fb7c5d8.png)](https://doc.rust-lang.org/nightly/std/string/struct.String.html#implementations) [New](https://jacob.hoffman-andrews.com/rust/outdent-methods/std/string/struct.String.html#implementations): [![image](https://user-images.githubusercontent.com/220205/138392479-b45fce3f-bf43-42e0-81ee-c4bb9ac35cda.png)](https://jacob.hoffman-andrews.com/rust/outdent-methods/std/string/struct.String.html#implementations)
…_ref_mut, r=oli-obk Mark `{array, slice}::{from_ref, from_mut}` as const fn This PR marks the following APIs as `const`: ```rust // core::array pub const fn from_ref<T>(s: &T) -> &[T; 1]; pub const fn from_mut<T>(s: &mut T) -> &mut [T; 1]; // core::slice pub const fn from_ref<T>(s: &T) -> &[T]; pub const fn from_mut<T>(s: &mut T) -> &mut [T]; ``` Note that `from_ref` methods require `const_raw_ptr_deref` feature (which seems totally fine, since it's being stabilized, see rust-lang#89551), `from_mut` methods require `const_mut_refs` (which seems fine too since this PR marks `from_mut` functions as const unstable). r? `@oli-obk`
…petrochenkov Repace use of `static_nobundle` with `native_link_modifiers` within Rust codebase This fixes warnings when building Rust and running tests: ``` warning: library kind `static-nobundle` has been superseded by specifying `-bundle` on library kind `static`. Try `static:-bundle` warning: `rustc_llvm` (lib) generated 2 warnings (1 duplicate) ```
@bors r+ p=5 rollup=never |
📌 Commit bdf54db 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
Oct 24, 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-bors
Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
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:
{array, slice}::{from_ref, from_mut}
as const fn #90162 (Mark{array, slice}::{from_ref, from_mut}
as const fn)static_nobundle
withnative_link_modifiers
within Rust codebase #90205 (Repace use ofstatic_nobundle
withnative_link_modifiers
within Rust codebase)Failed merges:
r? @ghost
@rustbot modify labels: rollup
Create a similar rollup