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 13 pull requests #76907

Closed
wants to merge 45 commits into from
Closed

Commits on Aug 11, 2020

  1. Configuration menu
    Copy the full SHA
    00d537d View commit details
    Browse the repository at this point in the history

Commits on Aug 30, 2020

  1. lint/ty: move fns to avoid abstraction violation

    This commit moves `transparent_newtype_field` and `is_zst` to
    `LateContext` where they are used, rather than being on the `VariantDef`
    and `TyS` types.
    
    Signed-off-by: David Wood <david@davidtw.co>
    davidtwco committed Aug 30, 2020
    Configuration menu
    Copy the full SHA
    0f2bd56 View commit details
    Browse the repository at this point in the history

Commits on Aug 31, 2020

  1. Stabilize some Option methods as const

    Stabilize the following methods of `Option` as const:
     - `is_some`
     - `is_none`
     - `as_ref`
    
    Possible because of stabilization of rust-lang#49146 (Allow if and match in constants).
    CDirkx committed Aug 31, 2020
    Configuration menu
    Copy the full SHA
    db109c6 View commit details
    Browse the repository at this point in the history

Commits on Sep 3, 2020

  1. Configuration menu
    Copy the full SHA
    04e4a39 View commit details
    Browse the repository at this point in the history

Commits on Sep 4, 2020

  1. Add [T; N]: TryFrom<Vec<T>>

    This is very similar to the existing `Box<[T; N]>: TryFrom<Box<[T]>>`, but allows avoiding the `shrink_to_fit` if you have a vector and not a boxed slice.
    scottmcm committed Sep 4, 2020
    Configuration menu
    Copy the full SHA
    6092828 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    6cb6716 View commit details
    Browse the repository at this point in the history

Commits on Sep 5, 2020

  1. Nightly is currently 1.48

    scottmcm authored Sep 5, 2020
    Configuration menu
    Copy the full SHA
    2c8a4c8 View commit details
    Browse the repository at this point in the history

Commits on Sep 6, 2020

  1. Configuration menu
    Copy the full SHA
    685f042 View commit details
    Browse the repository at this point in the history

Commits on Sep 7, 2020

  1. Typo fix

    Thanks, Amanieu
    
    Co-authored-by: Amanieu d'Antras <amanieu@gmail.com>
    scottmcm and Amanieu authored Sep 7, 2020
    Configuration menu
    Copy the full SHA
    3d89ee9 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    caeb554 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    4b5cd54 View commit details
    Browse the repository at this point in the history
  4. Separate feature flags

    Co-authored-by: Ivan Tham <pickfire@riseup.net>
    RalfJung and pickfire authored Sep 7, 2020
    Configuration menu
    Copy the full SHA
    47668ed View commit details
    Browse the repository at this point in the history
  5. add missing feature flag

    RalfJung committed Sep 7, 2020
    Configuration menu
    Copy the full SHA
    284b169 View commit details
    Browse the repository at this point in the history

Commits on Sep 12, 2020

  1. Configuration menu
    Copy the full SHA
    91f7d76 View commit details
    Browse the repository at this point in the history

Commits on Sep 15, 2020

  1. Configuration menu
    Copy the full SHA
    f567287 View commit details
    Browse the repository at this point in the history

Commits on Sep 16, 2020

  1. library/panic_unwind: Add UNWIND_DATA_REG for RISC-V 32-bit

    Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
    alistair23 committed Sep 16, 2020
    Configuration menu
    Copy the full SHA
    de0d55c View commit details
    Browse the repository at this point in the history
  2. library/std: linux: Add support for RISC-V 32-bit

    Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
    alistair23 committed Sep 16, 2020
    Configuration menu
    Copy the full SHA
    84fe26c View commit details
    Browse the repository at this point in the history
  3. library/std: raw: Add support for RISC-V 32-bit

    Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
    alistair23 committed Sep 16, 2020
    Configuration menu
    Copy the full SHA
    cd066c9 View commit details
    Browse the repository at this point in the history
  4. library/std: sys_common: Add support for RISC-V 32-bit

    Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
    alistair23 committed Sep 16, 2020
    Configuration menu
    Copy the full SHA
    cf07535 View commit details
    Browse the repository at this point in the history
  5. library/unwind: Add support for RISC-V 32-bit

    Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
    alistair23 committed Sep 16, 2020
    Configuration menu
    Copy the full SHA
    0f3ccbd View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    be37265 View commit details
    Browse the repository at this point in the history
  7. tools/build-manifest: Add support for RISC-V 32-bit

    Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
    alistair23 committed Sep 16, 2020
    Configuration menu
    Copy the full SHA
    3e94295 View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    1d93048 View commit details
    Browse the repository at this point in the history
  9. Configuration menu
    Copy the full SHA
    230355f View commit details
    Browse the repository at this point in the history
  10. library/panic_unwind: Consolidate RV32 and RV64

    Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
    alistair23 committed Sep 16, 2020
    Configuration menu
    Copy the full SHA
    fd76268 View commit details
    Browse the repository at this point in the history
  11. library/unwind: Consolidate RV32 and RV64

    Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
    alistair23 committed Sep 16, 2020
    Configuration menu
    Copy the full SHA
    57b2da8 View commit details
    Browse the repository at this point in the history
  12. don't lazily evaulate some trivial values for Option::None replacemen…

    …ts (clippy::unnecessary_lazy_evaluations)
    matthiaskrgr committed Sep 16, 2020
    Configuration menu
    Copy the full SHA
    0e34142 View commit details
    Browse the repository at this point in the history

Commits on Sep 17, 2020

  1. library/unwind: Add missing )

    Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
    alistair23 committed Sep 17, 2020
    Configuration menu
    Copy the full SHA
    3d1b6d6 View commit details
    Browse the repository at this point in the history

Commits on Sep 19, 2020

  1. Configuration menu
    Copy the full SHA
    3f68ae4 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    5c30a16 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    1e2dba1 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    1bfe5ef View commit details
    Browse the repository at this point in the history
  5. Rollup merge of rust-lang#73963 - hellow554:unsafe_path, r=Mark-Simul…

    …acrum
    
    deny(unsafe_op_in_unsafe_fn) in libstd/path.rs
    
    The libstd/path.rs part of rust-lang#73904 . Wraps the two calls to an unsafe fn Initializer::nop() in an unsafe block.
    RalfJung authored Sep 19, 2020
    Configuration menu
    Copy the full SHA
    651415a View commit details
    Browse the repository at this point in the history
  6. Rollup merge of rust-lang#75099 - davidtwco:is-zst-abstraction-violat…

    …ion, r=eddyb
    
    lint/ty: move fns to avoid abstraction violation
    
    This PR moves `transparent_newtype_field` and `is_zst` to `LateContext` where they are used, rather than being on the `VariantDef` and `TyS` types, hopefully addressing @eddyb's concern [from this comment](rust-lang#74340 (comment)).
    RalfJung authored Sep 19, 2020
    Configuration menu
    Copy the full SHA
    6bae1cd View commit details
    Browse the repository at this point in the history
  7. Rollup merge of rust-lang#75580 - JulianKnodt:or_pattern, r=wesleywiser

    Add test for checking duplicated branch or-patterns
    
    This adds a regression test for checking `or-patterns` in MIR as shown in rust-lang#75439.
    This doesn't introduce a fix as I'm not sure where it would go(I suspect maybe here: src/librustc_mir_build/build/matches/mod.rs), and I'm not particularly able to fix it.
    
    cc: @lzutao
    RalfJung authored Sep 19, 2020
    Configuration menu
    Copy the full SHA
    47fc3ed View commit details
    Browse the repository at this point in the history
  8. Rollup merge of rust-lang#76135 - CDirkx:const-option, r=dtolnay

    Stabilize some Option methods as const
    
    Stabilize the following methods of `Option` as const:
     - `is_some`
     - `is_none`
     - `as_ref`
    
    These methods are currently const under the unstable feature `const_option` (tracking issue: rust-lang#67441).
    I believe these methods to be eligible for stabilization because of the stabilization of rust-lang#49146 (Allow if and match in constants) and the trivial implementations, see also:  [PR#75463](rust-lang#75463).
    
    Related: rust-lang#76225
    RalfJung authored Sep 19, 2020
    Configuration menu
    Copy the full SHA
    af0594f View commit details
    Browse the repository at this point in the history
  9. Rollup merge of rust-lang#76310 - scottmcm:array-try_from-vec, r=dtolnay

    Add `[T; N]: TryFrom<Vec<T>>` (insta-stable)
    
    This is very similar to the [existing](https://doc.rust-lang.org/nightly/std/convert/trait.TryFrom.html#impl-TryFrom%3CBox%3C%5BT%5D%3E%3E) `Box<[T; N]>: TryFrom<Box<[T]>>`, but allows avoiding the `shrink_to_fit` if you have a vector and not a boxed slice.
    
    Like the slice equivalents of this, it fails if the length of the vector is not exactly `N`.
    This uses `Vec<T>` as the `Error` type to return the input, like how the `Rc<[T]> -> Rc<[T; N]>` (and Arc) ones also reflect the input directly in the error type.
    
    ```rust
    #[stable(feature = "array_try_from_vec", since = "1.47.0")]
    impl<T, const N: usize> TryFrom<Vec<T>> for [T; N] {
        type Error = Vec<T>;
        fn try_from(mut vec: Vec<T>) -> Result<[T; N], Vec<T>>;
    }
    ```
    
    Inspired by this zulip thread: https://rust-lang.zulipchat.com/#narrow/stream/219381-t-libs/topic/APIs.20for.20getting.20stuff.20from.20a.20Vec.20by.20owned/near/209048103
    RalfJung authored Sep 19, 2020
    Configuration menu
    Copy the full SHA
    f3a476d View commit details
    Browse the repository at this point in the history
  10. Rollup merge of rust-lang#76400 - pickfire:patch-5, r=dtolnay

    Clean up vec benches bench_in_place style
    RalfJung authored Sep 19, 2020
    Configuration menu
    Copy the full SHA
    0d80a97 View commit details
    Browse the repository at this point in the history
  11. Rollup merge of rust-lang#76434 - RalfJung:black-box, r=Mark-Simulacrum

    do not inline black_box when building for Miri
    
    We cannot do the assembly trick in Miri, but let's at least make sure MIR inlining does not circumvent the black_box.
    
    Also use black_box instead of local optimization barriers in a few const tests.
    RalfJung authored Sep 19, 2020
    Configuration menu
    Copy the full SHA
    d46d8f1 View commit details
    Browse the repository at this point in the history
  12. Rollup merge of rust-lang#76492 - fusion-engineering-forks:int-bits, …

    …r=dtolnay
    
    Add associated constant `BITS` to all integer types
    
    Recently I've regularly come across this snippet (in a few different crates, including `core` and `std`):
    ```rust
    std::mem::size_of<usize>() * 8
    ```
    
    I think it's time for a `usize::BITS`.
    RalfJung authored Sep 19, 2020
    Configuration menu
    Copy the full SHA
    e00725a View commit details
    Browse the repository at this point in the history
  13. Rollup merge of rust-lang#76636 - RalfJung:miri-size-assert, r=oli-obk

    assert ScalarMaybeUninit size
    
    I noticed most low-level Miri types have such an assert but `ScalarMaybeUninit` does not, so let's add that. Good t see that the `Option`-like optimization kicks in and this is no bigger than `Scalar`. :)
    
    r? @oli-obk
    RalfJung authored Sep 19, 2020
    Configuration menu
    Copy the full SHA
    d8892b4 View commit details
    Browse the repository at this point in the history
  14. Rollup merge of rust-lang#76749 - guswynn:hir_ranges, r=estebank

    give *even better* suggestion when matching a const range
    
    notice that the err already has "constant defined here"
    so this is now *exceedingly clear*
    
    extension to rust-lang#76222
    
    r? @estebank
    RalfJung authored Sep 19, 2020
    Configuration menu
    Copy the full SHA
    30e8ec6 View commit details
    Browse the repository at this point in the history
  15. Rollup merge of rust-lang#76757 - matthiaskrgr:clippy_try_into, r=lcnr

    don't convert types to the same type with try_into (clippy::useless_conversion)
    RalfJung authored Sep 19, 2020
    Configuration menu
    Copy the full SHA
    141ba48 View commit details
    Browse the repository at this point in the history
  16. Rollup merge of rust-lang#76796 - jyn514:wrong-stage, r=shepmaster

    Give a better error message when x.py uses the wrong stage for CI
    
    r? @shepmaster
    RalfJung authored Sep 19, 2020
    Configuration menu
    Copy the full SHA
    10c1ddb View commit details
    Browse the repository at this point in the history
  17. Rollup merge of rust-lang#76798 - alistair23:alistair/rv32-linux, r=j…

    …yn514
    
    Build fixes for RISC-V 32-bit Linux support
    
    This fixes build issues with the 32-bit RISC-V port.
    RalfJung authored Sep 19, 2020
    Configuration menu
    Copy the full SHA
    72ff47c View commit details
    Browse the repository at this point in the history