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 6 pull requests #94383

Closed
wants to merge 12 commits into from

Commits on Jan 12, 2022

  1. Tweak diagnostics

    * Recover from invalid `'label: ` before block.
    * Make suggestion to enclose statements in a block multipart.
    * Point at `match`, `while`, `loop` and `unsafe` keywords when failing
      to parse their expression.
    * Do not suggest `{ ; }`.
    * Do not suggest `|` when very unlikely to be what was wanted (in `let`
      statements).
    estebank committed Jan 12, 2022
    Configuration menu
    Copy the full SHA
    49479b4 View commit details
    Browse the repository at this point in the history

Commits on Feb 3, 2022

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

Commits on Feb 10, 2022

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

Commits on Feb 25, 2022

  1. Configuration menu
    Copy the full SHA
    6b68882 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    45a441b View commit details
    Browse the repository at this point in the history
  3. Add one more case to avoid ICE

    ouz-a authored and Mark-Simulacrum committed Feb 25, 2022
    Configuration menu
    Copy the full SHA
    8c96487 View commit details
    Browse the repository at this point in the history
  4. Rollup merge of rust-lang#92823 - estebank:tweak-diag, r=jackh726

    Tweak diagnostics
    
    * Recover from invalid `'label: ` before block.
    * Make suggestion to enclose statements in a block multipart.
    * Point at `match`, `while`, `loop` and `unsafe` keywords when failing
      to parse their expression. (Fix rust-lang#92705.)
    * Do not suggest `{ ; }`.
    * Do not suggest `|` when very unlikely to be what was wanted (in `let`
      statements).
    matthiaskrgr authored Feb 25, 2022
    Configuration menu
    Copy the full SHA
    e22abfb View commit details
    Browse the repository at this point in the history
  5. Rollup merge of rust-lang#93603 - connorff:compute-polonius-liveness-…

    …facts-flag, r=ecstatic-morse
    
    Populate liveness facts when calling `get_body_with_borrowck_facts` without `-Z polonius`
    
    For a new feature of [Flowistry](https://github.com/willcrichton/flowistry), a static-analysis tool, we need to obtain a `mir::Body`'s liveness facts using `get_body_with_borrowck_facts` (added in rust-lang#86977). We'd like to do this without passing `-Z polonius` as a compiler arg to avoid borrow checking the entire crate.
    
    Support for doing this was added in rust-lang#88983, but the Polonius input facts used for liveness analysis are empty. This happens because the liveness input facts are populated in `liveness::generate` depending only on the value of `AllFacts::enabled` (which is toggled via compiler args).
    
    This PR propagates the [`use_polonius`](https://github.com/rust-lang/rust/blob/8b09ba6a5d5c644fe0f1c27c7f9c80b334241707/compiler/rustc_borrowck/src/nll.rs#L168) flag to `liveness::generate` to support populating liveness facts without requiring the `-Z polonius` flag.
    
    This fix is somewhat patchy - if it'd be better to add more widely-accessible state (like `AllFacts::enabled`) I'd be open to ideas!
    matthiaskrgr authored Feb 25, 2022
    Configuration menu
    Copy the full SHA
    e101c19 View commit details
    Browse the repository at this point in the history
  6. Rollup merge of rust-lang#93870 - tmiasko:const-precise-live-drops-wi…

    …th-coverage, r=ecstatic-morse
    
    Fix switch on discriminant detection in a presence of coverage counters
    
    Fixes rust-lang#93848.
    
    r? `@ecstatic-morse`
    matthiaskrgr authored Feb 25, 2022
    Configuration menu
    Copy the full SHA
    8b72adb View commit details
    Browse the repository at this point in the history
  7. Rollup merge of rust-lang#94355 - ouz-a:master, r=oli-bok

    Add one more case to avoid ICE
    
    Fix for the  rust-lang#94291, added one more case to related function to avoid ICE.
    
    Not sure if my test is in the correct place 😅
    matthiaskrgr authored Feb 25, 2022
    Configuration menu
    Copy the full SHA
    f5cc8cb View commit details
    Browse the repository at this point in the history
  8. Rollup merge of rust-lang#94363 - aDotInTheVoid:fmt-needless-borrows,…

    … r=scottmcm
    
    Remove needless borrows from core::fmt
    matthiaskrgr authored Feb 25, 2022
    Configuration menu
    Copy the full SHA
    fd38344 View commit details
    Browse the repository at this point in the history
  9. Rollup merge of rust-lang#94377 - cynecx:fix-used-with-args, r=nikic

    `check_used` should only look at actual `used` attributes
    
    cc? rust-lang#94348
    r? `@nikic`
    matthiaskrgr authored Feb 25, 2022
    Configuration menu
    Copy the full SHA
    1136768 View commit details
    Browse the repository at this point in the history