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 #126671

Merged
merged 22 commits into from
Jun 19, 2024
Merged

Rollup of 7 pull requests #126671

merged 22 commits into from
Jun 19, 2024

Commits on May 13, 2024

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

Commits on Jun 16, 2024

  1. Add tests

    Nadrieril committed Jun 16, 2024
    Configuration menu
    Copy the full SHA
    6b84d75 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    e74b30e View commit details
    Browse the repository at this point in the history
  3. Always set otherwise_blocks

    Nadrieril committed Jun 16, 2024
    Configuration menu
    Copy the full SHA
    5fe2ca6 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    764f086 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    ce374fc View commit details
    Browse the repository at this point in the history
  6. Expand or-candidates mixed with candidates above

    We can't mix them with candidates below them, but we can mix them with
    candidates above.
    Nadrieril committed Jun 16, 2024
    Configuration menu
    Copy the full SHA
    7b764be View commit details
    Browse the repository at this point in the history

Commits on Jun 18, 2024

  1. Configuration menu
    Copy the full SHA
    af10880 View commit details
    Browse the repository at this point in the history
  2. Apply suggestions from oli-obk's review

    Co-authored-by: Oli Scherer <github35764891676564198441@oli-obk.de>
    zetanumbers and oli-obk committed Jun 18, 2024
    Configuration menu
    Copy the full SHA
    1a8eae1 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    de473a5 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    83cb760 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    c1597f9 View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    977d3f6 View commit details
    Browse the repository at this point in the history

Commits on Jun 19, 2024

  1. Make pretty printing for f16 and f128 consistent

    Currently the docs show e.g.
    
        {transmute(0xfffeffffffffffffffffffffffffffff): f128}
    
    for f128 constants. This should fix that to instead use apfloat for
    printing, as is done for `f32` and `f64`.
    tgross35 committed Jun 19, 2024
    Configuration menu
    Copy the full SHA
    1299aef View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    2126c1d View commit details
    Browse the repository at this point in the history
  3. Rollup merge of rust-lang#123782 - oli-obk:equal_tait_args, r=compile…

    …r-errors
    
    Test that opaque types can't have themselves as a hidden type with incompatible lifetimes
    
    fixes rust-lang#122876
    
    This PR used to add extra logic to prevent those cases, but after rust-lang#113169 this is implicitly rejected, because such usages are not defining.
    fmease authored Jun 19, 2024
    Configuration menu
    Copy the full SHA
    f03bd96 View commit details
    Browse the repository at this point in the history
  4. Rollup merge of rust-lang#124580 - gurry:124556-suggest-remove-tuple-…

    …field, r=jackh726
    
    Suggest removing unused tuple fields if they are the last fields
    
    Fixes rust-lang#124556
    
    We now check if dead/unused fields are the last fields of the tuple and suggest their removal instead of suggesting them to be changed to `()`.
    fmease authored Jun 19, 2024
    Configuration menu
    Copy the full SHA
    96144c9 View commit details
    Browse the repository at this point in the history
  5. Rollup merge of rust-lang#125787 - Oneirical:infinite-test-a-novel, r…

    …=jieyouxu
    
    Migrate `bin-emit-no-symbols` `run-make` test to `rmake`
    
    Part of rust-lang#121876 and the associated [Google Summer of Code project](https://blog.rust-lang.org/2024/05/01/gsoc-2024-selected-projects.html).
    
    try-job: x86_64-msvc
    try-job: armhf-gnu
    fmease authored Jun 19, 2024
    Configuration menu
    Copy the full SHA
    1139111 View commit details
    Browse the repository at this point in the history
  6. Rollup merge of rust-lang#126553 - Nadrieril:expand-or-pat-into-above…

    …, r=matthewjasper
    
    match lowering: expand or-candidates mixed with candidates above
    
    This PR tweaks match lowering of or-patterns. Consider this:
    ```rust
    match (x, y) {
        (1, true) => 1,
        (2, false) => 2,
        (1 | 2, true | false) => 3,
        (3 | 4, true | false) => 4,
        _ => 5,
    }
    ```
    One might hope that this can be compiled to a single `SwitchInt` on `x` followed by some boolean checks. Before this PR, we compile this to 3 `SwitchInt`s on `x`, because an arm that contains more than one or-pattern was compiled on its own. This PR groups branch `3` with the two branches above, getting us down to 2 `SwitchInt`s on `x`.
    
    We can't in general expand or-patterns freely, because this interacts poorly with another optimization we do: or-pattern simplification. When an or-pattern doesn't involve bindings, we branch the success paths of all its alternatives to the same block. The drawback is that in a case like:
    ```rust
    match (1, true) {
        (1 | 2, false) => unreachable!(),
        (2, _) => unreachable!(),
        _ => {}
    }
    ```
    if we used a single `SwitchInt`, by the time we test `false` we don't know whether we came from the `1` case or the `2` case, so we don't know where to go if `false` doesn't match.
    
    Hence the limitation: we can process or-pattern alternatives alongside candidates that precede it, but not candidates that follow it. (Unless the or-pattern is the only remaining match pair of its candidate, in which case we can process it alongside whatever).
    
    This PR allows the processing of or-pattern alternatives alongside candidates that precede it. One benefit is that we now process or-patterns in a single place in `mod.rs`.
    
    r? ``@matthewjasper``
    fmease authored Jun 19, 2024
    Configuration menu
    Copy the full SHA
    e111e99 View commit details
    Browse the repository at this point in the history
  7. Rollup merge of rust-lang#126594 - zetanumbers:fix-cross-crate-async-…

    …drop-glue, r=oli-obk
    
    Make async drop code more consistent with regular drop code
    
    Fixes rust-lang#126573
    
    Relates to rust-lang#126482
    
    r? ````@petrochenkov````
    fmease authored Jun 19, 2024
    Configuration menu
    Copy the full SHA
    ef062ea View commit details
    Browse the repository at this point in the history
  8. Rollup merge of rust-lang#126654 - tgross35:f16-f128-pretty-print, r=…

    …jackh726
    
    Make pretty printing for `f16` and `f128` consistent
    
    Currently the docs show e.g.
    
        {transmute(0xfffeffffffffffffffffffffffffffff): f128}
    
    for f128 constants. This should fix that to instead use apfloat for printing, as is done for `f32` and `f64`.
    fmease authored Jun 19, 2024
    Configuration menu
    Copy the full SHA
    2bc0cf2 View commit details
    Browse the repository at this point in the history
  9. Rollup merge of rust-lang#126656 - fmease:skip-debug-for-_, r=compile…

    …r-errors
    
    rustc_type_ir: Omit some struct fields from Debug output
    
    r? compiler-errors or compiler
    fmease authored Jun 19, 2024
    Configuration menu
    Copy the full SHA
    b980f6d View commit details
    Browse the repository at this point in the history