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 11 pull requests #80093

Closed
wants to merge 36 commits into from

Commits on Dec 6, 2020

  1. Configuration menu
    Copy the full SHA
    77d80b2 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    f9cc626 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    cfaaa21 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    bab2080 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    f3d4aa6 View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    61e69bc View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    0917260 View commit details
    Browse the repository at this point in the history

Commits on Dec 8, 2020

  1. Remove memoization leftovers

    Tunahan Karlibas committed Dec 8, 2020
    Configuration menu
    Copy the full SHA
    7cb74ed View commit details
    Browse the repository at this point in the history

Commits on Dec 9, 2020

  1. Extra assertions in eval_body_using_ecx to disallow queries for

    functions that does allocations
    Tunahan Karlibas committed Dec 9, 2020
    Configuration menu
    Copy the full SHA
    de1cd4b View commit details
    Browse the repository at this point in the history

Commits on Dec 10, 2020

  1. fix issue rust-lang#78496

    wecing committed Dec 10, 2020
    Configuration menu
    Copy the full SHA
    c6f2d49 View commit details
    Browse the repository at this point in the history
  2. update comments

    wecing committed Dec 10, 2020
    Configuration menu
    Copy the full SHA
    78c0680 View commit details
    Browse the repository at this point in the history
  3. fix test case issue ref

    wecing committed Dec 10, 2020
    Configuration menu
    Copy the full SHA
    3812f70 View commit details
    Browse the repository at this point in the history
  4. Remove unnecessary check and fix local_def_id parameter

    Tunahan Karlibas committed Dec 10, 2020
    Configuration menu
    Copy the full SHA
    b6f7eef View commit details
    Browse the repository at this point in the history

Commits on Dec 11, 2020

  1. add missing constraints

    Tunahan Karlibas committed Dec 11, 2020
    Configuration menu
    Copy the full SHA
    a03feaa View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    ed80815 View commit details
    Browse the repository at this point in the history

Commits on Dec 13, 2020

  1. Configuration menu
    Copy the full SHA
    0f30b7d View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    d75618e View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    94fd1d3 View commit details
    Browse the repository at this point in the history
  4. fix typo

    Stupremee committed Dec 13, 2020
    Configuration menu
    Copy the full SHA
    09d528e View commit details
    Browse the repository at this point in the history

Commits on Dec 14, 2020

  1. Configuration menu
    Copy the full SHA
    6c7835e View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    357565d View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    01c2520 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    777ca99 View commit details
    Browse the repository at this point in the history

Commits on Dec 16, 2020

  1. Configuration menu
    Copy the full SHA
    cfc38d2 View commit details
    Browse the repository at this point in the history
  2. Allow since="TBD" for rustc_deprecated

    bstrie committed Dec 16, 2020
    Configuration menu
    Copy the full SHA
    1e1ca28 View commit details
    Browse the repository at this point in the history
  3. Rollup merge of rust-lang#79051 - LeSeulArtichaut:if-let-guard, r=mat…

    …thewjasper
    
    Implement if-let match guards
    
    Implements rust-lang/rfcs#2294 (tracking issue: rust-lang#51114).
    
    I probably should do a few more things before this can be merged:
    - [x] Add tests (added basic tests, more advanced tests could be done in the future?)
    - [x] Add lint for exhaustive if-let guard (comparable to normal if-let statements)
    - [x] Fix clippy
    
    However since this is a nightly feature maybe it's fine to land this and do those steps in follow-up PRs.
    
    Thanks a lot `@matthewjasper` ❤️ for helping me with lowering to MIR! Would you be interested in reviewing this?
    r? `@ghost` for now
    Dylan-DPC authored Dec 16, 2020
    Configuration menu
    Copy the full SHA
    cec4573 View commit details
    Browse the repository at this point in the history
  4. Rollup merge of rust-lang#79790 - LeSeulArtichaut:issue-79683, r=lcnr

    Take into account negative impls in "trait item not found" suggestions
    
    This removes the suggestion to implement a trait for a type when that type already has a negative implementation for the trait, and replaces it with a note to point out that the trait is explicitely unimplemented, as suggested by `@scottmcm.`
    
    Helps with rust-lang#79683.
    
    r? `@scottmcm` do you want to review this?
    Dylan-DPC authored Dec 16, 2020
    Configuration menu
    Copy the full SHA
    553d632 View commit details
    Browse the repository at this point in the history
  5. Rollup merge of rust-lang#79840 - dvtkrlbs:issue-79667, r=oli-obk

    Remove memoization leftovers from constant evaluation machine
    
    Closes rust-lang#79667
    Dylan-DPC authored Dec 16, 2020
    Configuration menu
    Copy the full SHA
    3d8241d View commit details
    Browse the repository at this point in the history
  6. Rollup merge of rust-lang#79877 - bstrie:depinfut, r=oli-obk

    Allow `since="TBD"` for rustc_deprecated
    
    Closes rust-lang#78381.
    
    This PR only affects `#[rustc_deprecated]`, not `#[deprecated]`, so there is no effect on any stable language feature.
    
    Likewise this PR only implements `since="TBD"`, it does not actually tag any library functions with it, so there is no effect on any stable API.
    
    Overview of changes:
    
    * `rustc_middle/stability.rs`:
        * change `deprecation_in_effect` function to return `false` when `since="TBD"`
        * tidy up the compiler output when a deprecated item has `since="TBD"`
    * `rustc_passes/stability.rs`:
        * allow `since="TBD"` to pass the sanity check for stable_version < deprecated_version
        * refactor the "invalid stability version" and "invalid deprecation version" error into separate errors
    * rustdoc: make `since="TBD"` message on a deprecated item's page match the command-line deprecation output
    * tests:
        * test rustdoc output
        * test that the `deprecated_in_future` lint fires when `since="TBD"`
        * test the new "invalid deprecation version" error message
    Dylan-DPC authored Dec 16, 2020
    Configuration menu
    Copy the full SHA
    88e2ee1 View commit details
    Browse the repository at this point in the history
  7. Rollup merge of rust-lang#79882 - wecing:master, r=oli-obk

    Fix issue rust-lang#78496
    
    EarlyOtherwiseBranch finds MIR structures like:
    
    ```
    bb0: {
      ...
      _2 = discriminant(X)
      ...
      switchInt(_2) -> [1_isize: bb1, otherwise: bb3]
    }
    bb1: {
      ...
      _3 = discriminant(Y)
      ...
      switchInt(_3) -> [1_isize: bb2, otherwise: bb3]
    }
    bb2: {...}
    bb3: {...}
    ```
    
    And transforms them into something like:
    
    ```
    bb0: {
      ...
      _2 = discriminant(X)
      _3 = discriminant(Y)
      _4 = Eq(_2, _3)
      switchInt(_4) -> [true: bb4, otherwise: bb3]
    }
    bb2: {...} // unchanged
    bb3: {...} // unchanged
    bb4: {
      switchInt(_2) -> [1_isize: bb2, otherwise: bb3]
    }
    ```
    
    But that is not always a safe thing to do -- sometimes the early `otherwise` branch is necessary so the later block could assume the value of `discriminant(X)`.
    
    I am not totally sure what's the best way to detect that, but fixing rust-lang#78496 should be easy -- we just check if `X` is a sub-expression of `Y`. A more precise test might be to check if `Y` contains a `Downcast(1)` of `X`, but I think this might be good enough.
    
    Fix rust-lang#78496
    Dylan-DPC authored Dec 16, 2020
    Configuration menu
    Copy the full SHA
    bd93050 View commit details
    Browse the repository at this point in the history
  8. Rollup merge of rust-lang#79945 - jackh726:existential_trait_ref, r=n…

    …ikomatsakis
    
    Move binder for dyn to each list item
    
    This essentially changes `ty::Binder<&'tcx List<ExistentialTraitRef>>` to `&'tcx List<ty::Binder<ExistentialTraitRef>>`.
    
    This is a first step in moving the `dyn Trait` representation closer to Chalk, which we've talked about in ``````@rust-lang/wg-traits.``````
    
    r? ``````@nikomatsakis``````
    Dylan-DPC authored Dec 16, 2020
    Configuration menu
    Copy the full SHA
    3dafad2 View commit details
    Browse the repository at this point in the history
  9. Rollup merge of rust-lang#80003 - Stupremee:fix-zst-vecdeque-conversi…

    …on-panic, r=dtolnay
    
    Fix overflow when converting ZST Vec to VecDeque
    
    ```rust
    let v = vec![(); 100];
    let queue = VecDeque::from(v);
    println!("{:?}", queue);
    ```
    This code will currently panic with a capacity overflow.
    This PR resolves this issue and makes the code run fine.
    
    Resolves rust-lang#78532
    Dylan-DPC authored Dec 16, 2020
    Configuration menu
    Copy the full SHA
    69db829 View commit details
    Browse the repository at this point in the history
  10. Rollup merge of rust-lang#80006 - ssomers:btree_cleanup_6, r=Mark-Sim…

    …ulacrum
    
    BTreeMap: more expressive local variables in merge
    
    r? ``````@Mark-Simulacrum``````
    Dylan-DPC authored Dec 16, 2020
    Configuration menu
    Copy the full SHA
    6afef41 View commit details
    Browse the repository at this point in the history
  11. Rollup merge of rust-lang#80022 - ssomers:btree_cleanup_8, r=Mark-Sim…

    …ulacrum
    
    BTreeSet: simplify implementation of pop_first/pop_last
    
    …and stop it interfering in rust-lang#79245.
    r? ``````@Mark-Simulacrum``````
    Dylan-DPC authored Dec 16, 2020
    Configuration menu
    Copy the full SHA
    fe6910e View commit details
    Browse the repository at this point in the history
  12. Rollup merge of rust-lang#80026 - JohnTitor:separator-insensitive, r=…

    …Mark-Simulacrum
    
    expand-yaml-anchors: Make the output directory separator-insensitive
    
    Fixes rust-lang#75709
    Dylan-DPC authored Dec 16, 2020
    Configuration menu
    Copy the full SHA
    6c7de3f View commit details
    Browse the repository at this point in the history
  13. Rollup merge of rust-lang#80035 - ChayimFriedman2:patch-1, r=nagisa

    Optimization for bool's PartialOrd impl
    
    Fix rust-lang#80034.
    Dylan-DPC authored Dec 16, 2020
    Configuration menu
    Copy the full SHA
    7496c37 View commit details
    Browse the repository at this point in the history