Skip to content
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 #84535

Closed
wants to merge 32 commits into from

Commits on Apr 21, 2021

  1. Configuration menu
    Copy the full SHA
    259a368 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    7cb1dcd View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    312b4fd View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    d3e0d2f View commit details
    Browse the repository at this point in the history

Commits on Apr 22, 2021

  1. Cleanup std::os

    CDirkx committed Apr 22, 2021
    Configuration menu
    Copy the full SHA
    02a2fab View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    f728116 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    4ac44ee View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    6ca35de View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    ba5fb6f View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    3c139c7 View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    7a74bf3 View commit details
    Browse the repository at this point in the history
  8. Allow documenting on hermit

    CDirkx committed Apr 22, 2021
    Configuration menu
    Copy the full SHA
    b5bed92 View commit details
    Browse the repository at this point in the history

Commits on Apr 23, 2021

  1. update Miri

    RalfJung committed Apr 23, 2021
    Configuration menu
    Copy the full SHA
    00c95a3 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    e4ce655 View commit details
    Browse the repository at this point in the history
  3. add tests for new behavior

    syvb committed Apr 23, 2021
    Configuration menu
    Copy the full SHA
    fc97ce6 View commit details
    Browse the repository at this point in the history

Commits on Apr 24, 2021

  1. Add regression test

    estebank committed Apr 24, 2021
    Configuration menu
    Copy the full SHA
    8629017 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    64ee9cc View commit details
    Browse the repository at this point in the history
  3. Tweak suggestion output

    estebank committed Apr 24, 2021
    Configuration menu
    Copy the full SHA
    fb1fb7d View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    0d52599 View commit details
    Browse the repository at this point in the history
  5. Implemented suggestion.

    Tor Hovland committed Apr 24, 2021
    Configuration menu
    Copy the full SHA
    ad78b50 View commit details
    Browse the repository at this point in the history
  6. fix sanitizer tests

    RalfJung committed Apr 24, 2021
    Configuration menu
    Copy the full SHA
    56c0fb6 View commit details
    Browse the repository at this point in the history
  7. Added a test.

    Tor Hovland committed Apr 24, 2021
    Configuration menu
    Copy the full SHA
    0e7489a View commit details
    Browse the repository at this point in the history
  8. Refactor.

    Tor Hovland committed Apr 24, 2021
    Configuration menu
    Copy the full SHA
    8bc81a0 View commit details
    Browse the repository at this point in the history
  9. More tests.

    Tor Hovland committed Apr 24, 2021
    Configuration menu
    Copy the full SHA
    05a5a11 View commit details
    Browse the repository at this point in the history
  10. One more test case.

    Tor Hovland committed Apr 24, 2021
    Configuration menu
    Copy the full SHA
    3b50461 View commit details
    Browse the repository at this point in the history

Commits on Apr 25, 2021

  1. Rollup merge of rust-lang#84200 - CDirkx:os, r=m-ou-se

    Move all `sys::ext` modules to `os`
    
    This PR moves all `sys::ext` modules to `os`, centralizing the location of all `os` code and simplifying the dependencies between `os` and `sys`.
    
    Because this also removes all uses `cfg_if!` on publicly exported items, where after rust-lang#81969 there were still a few left, this should properly work around rust-lang/rust-analyzer#6038.
    
    `@rustbot` label: +T-libs-impl
    Dylan-DPC committed Apr 25, 2021
    Configuration menu
    Copy the full SHA
    70647f1 View commit details
    Browse the repository at this point in the history
  2. Rollup merge of rust-lang#84216 - RalfJung:black-box, r=Mark-Simulacrum

    move core::hint::black_box under its own feature gate
    
    The `black_box` function had its own RFC and is tracked separately from the `test` feature at rust-lang#64102. Let's reflect this in the feature gate.
    
    To avoid breaking all the benchmarks, libtest's `test::black_box` is a wrapping definition, not a reexport -- this means it is still under the `test` feature gate.
    Dylan-DPC committed Apr 25, 2021
    Configuration menu
    Copy the full SHA
    e165b58 View commit details
    Browse the repository at this point in the history
  3. Rollup merge of rust-lang#84299 - lcnr:const-generics-defaults-name-r…

    …es, r=varkor
    
    various const parameter defaults improvements
    
    Actually resolve names in const parameter defaults, fixing `struct Foo<const N: usize = { usize::MAX }>`.
    
    ---
    Split generic parameter ban rib for types and consts, allowing
    ```rust
    #![feature(const_generics_defaults)]
    struct Q;
    struct Foo<T = Q, const Q: usize = 3>(T);
    ```
    
    ---
    Remove the type/const ordering restriction if `const_generics_defaults` is active, even if `const_generics` is not. allowing us to stabilize and test const param defaults separately.
    
    ---
    Check well formedness of const parameter defaults, eagerly emitting an error for `struct Foo<const N: usize = { 0 - 1 }>`
    
    ---
    Do not forbid const parameters in param defaults, allowing `struct Foo<const N: usize, T = [u8; N]>(T)` and `struct Foo<const N: usize, const M: usize = N>`. Note that this should not change anything which is stabilized, as on stable, type parameters must be in front of const parameters, which means that type parameter defaults are only allowed if no const parameters exist.
    
    We still forbid generic parameters inside of const param types.
    
    r? ``@varkor`` ``@petrochenkov``
    Dylan-DPC committed Apr 25, 2021
    Configuration menu
    Copy the full SHA
    ea1c221 View commit details
    Browse the repository at this point in the history
  4. Rollup merge of rust-lang#84481 - RalfJung:miri, r=RalfJung

    update Miri
    
    Cc ``@rust-lang/miri`` r? ``@ghost``
    Dylan-DPC committed Apr 25, 2021
    Configuration menu
    Copy the full SHA
    8509ccb View commit details
    Browse the repository at this point in the history
  5. Rollup merge of rust-lang#84486 - Smittyvb:else-if-let-hir-pretty-pri…

    …nt, r=petrochenkov
    
    Handle pretty printing of `else if let` clauses without ICEing
    
    When pretty printing the HIR of `if ... {} else if let ... {}` clauses, this displays it the `else if let` part as `match` it gets desugared to, the same way normal `if let` statements are currently displayed, instead of ICEing.
    
    ```rust
    pub fn main() {
        if true {
            // 1
        } else if let a = 1 {
            // 2
        } else {
            // 3
        }
    }
    ```
    
    now gets desugared (via `rustc -Zunpretty=hir,typed src/x.rs`) to:
    
    ```rust
    #[prelude_import]
    use ::std::prelude::rust_2015::*;
    #[macro_use]
    extern crate std;
    pub fn main() ({
                       (if (true as bool)
                           ({
                                // 1
                            } as
                               ()) else {match (1 as i32) {
                                             a => {
                                                 // 2
                                             }
                                             _ => {
                                                 // 3
                                             }
                                         }} as ())
                        } as ())
    ```
    
    For comparison, this code gets HIR prettyprinted the same way before and after this change:
    
    ```rust
    pub fn main() {
        if let a = 1 {
            // 2
        } else {
            // 3
        }
    }
    ```
    turns into
    ```rust
    #[prelude_import]
    use ::std::prelude::rust_2015::*;
    #[macro_use]
    extern crate std;
    pub fn main() ({
                       (match (1 as i32) {
                            a => {
                                // 2
                            }
                            _ => {
                                // 3
                            }
                        } as ())
                   } as ())
    ```
    
    This closes rust-lang#82329. It closes rust-lang#84434 as well, due to having the same root cause.
    Dylan-DPC committed Apr 25, 2021
    Configuration menu
    Copy the full SHA
    822c24c View commit details
    Browse the repository at this point in the history
  6. Rollup merge of rust-lang#84499 - estebank:issue-84272, r=jackh726

    Tweak trait not `use`d suggestion
    
    Fix rust-lang#84272. Follow up to rust-lang#83667.
    Dylan-DPC committed Apr 25, 2021
    Configuration menu
    Copy the full SHA
    d1e2564 View commit details
    Browse the repository at this point in the history
  7. Rollup merge of rust-lang#84516 - torhovland:issue-84114, r=estebank

    Add suggestion to "use break" when attempting to implicit-break a loop
    
    Fixes rust-lang#84114
    Dylan-DPC committed Apr 25, 2021
    Configuration menu
    Copy the full SHA
    a48c332 View commit details
    Browse the repository at this point in the history