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 9 pull requests #101246

Closed
wants to merge 188 commits into from
Closed

Conversation

matthiaskrgr
Copy link
Member

Successful merges:

Failed merges:

r? @ghost
@rustbot modify labels: rollup

Create a similar rollup

aldhsu and others added 30 commits August 2, 2022 22:00
- only compare where predicates to trait bounds when generating where
  clause specific message to fix rust-lang#9151
- use comparable_trait_ref to account for trait bound generics to fix rust-lang#8757
…repr(C)` type is compatible with the other type
This enables more thorough checking of types to avoid triggering on
custom Some and None enum variants
It is passed an argument that is never used.
…jgillot

Simplify visitors

By removing some unused arguments.

r? `@cjgillot`
Extend `if_then_some_else_none` to also suggest `bool::then_some`

Closes rust-lang#9094.

changelog: Extend `if_then_some_else_none` to also suggest `bool::then_some`
davidtwco and others added 13 commits August 31, 2022 13:48
Functions annotated with `#[rustc_lint_diagnostics]` are used by the
diagnostic migration lints to know when to lint, but functions that are
annotated with this attribute shouldn't themselves be linted.

Signed-off-by: David Wood <david.wood@huawei.com>
…, r=petrochenkov

Pretty printing give proper error message without panic

Fixes rust-lang#100770
…iser

Simplify MIR opt tests

This commit removes many cases of MIR opt tests emitting `.diff`s for more than one pass. These tests cannot be `unit-test`s, and so they are easy to break, and they also provide little value due to having excessively strong opinions over *how* a piece of code should be optimized.

Where reasonable, we instead add separate test files that only emit the `PreCodegen.after` MIR for code where we want to track what the end to end effect of the optimization pipeline on the example code is.

r? ``@wesleywiser``
…-when-appropriate, r=davidtwco

Suggest moving redundant generic args of an assoc fn to its trait

Closes rust-lang#89064
migrate rustc_query_system to use SessionDiagnostic

issues:
* variable list is not supported in fluent
* ~~cannot have two sub diagnostic with the same tag (eg. 2 .note or 2 .help)~~

allow multiple tag with SessionSubdiagnostic derive
Fix uintended diagnostic caused by `drain(..)`

Calling `drain(..)` makes later `suggestable_variants.is_empty()` always true, which makes the diagnostics unintended.
Link “? operator” to relevant chapter in The Book

Before, the text simply asked people to use a symbol which is hard to
search for. Now the text links back to the chapter on error
propagation in The Book. That should help people find the relevant
keywords for further searches.
…t-no-self-lint, r=fee1-dead

lint: avoid linting diag functions with diag lints

Functions annotated with `#[rustc_lint_diagnostics]` are used by the diagnostic migration lints to know when to lint, but functions that are annotated with this attribute shouldn't themselves be linted.

cc rust-lang#100717 rust-lang#101041 (comment)
@rustbot rustbot added A-translation Area: Translation infrastructure, and migrating existing diagnostics to SessionDiagnostic T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-libs Relevant to the library team, which will review and decide on the PR/issue. rollup A PR which is a rollup labels Aug 31, 2022
@matthiaskrgr
Copy link
Member Author

@bors r+ rollup=never p=9

@bors
Copy link
Contributor

bors commented Aug 31, 2022

📌 Commit d78ae31 has been approved by matthiaskrgr

It is now in the queue for this repository.

@bors bors added the S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. label Aug 31, 2022
@bors
Copy link
Contributor

bors commented Aug 31, 2022

⌛ Testing commit d78ae31 with merge 25680a093e948acf46637fc9cc289904e488994c...

@rust-log-analyzer
Copy link
Collaborator

The job test-various failed! Check out the build log: (web) (plain)

Click to see the possible cause of the failure (guessed by this bot)
test [mir-opt] src/test/mir-opt/inline/polymorphic-recursion.rs ... ok

failures:

---- [mir-opt] src/test/mir-opt/lower_intrinsics.rs stdout ----
105           StorageDead(_15);                // scope 0 at $DIR/lower_intrinsics.rs:+4:48: +4:49
106           StorageDead(_13);                // scope 0 at $DIR/lower_intrinsics.rs:+4:48: +4:49
107           _0 = const ();                   // scope 0 at $DIR/lower_intrinsics.rs:+0:30: +5:2
-           drop(_1) -> [return: bb5, unwind: bb6]; // scope 0 at $DIR/lower_intrinsics.rs:+5:1: +5:2
+           drop(_1) -> bb5;                 // scope 0 at $DIR/lower_intrinsics.rs:+5:1: +5:2
110   
111       bb5: {


112           return;                          // scope 0 at $DIR/lower_intrinsics.rs:+5:2: +5:2
-   
-   
-       bb6 (cleanup): {
-           resume;                          // scope 0 at $DIR/lower_intrinsics.rs:+0:1: +5:2
118   }
119   


thread '[mir-opt] src/test/mir-opt/lower_intrinsics.rs' panicked at 'Actual MIR output differs from expected MIR output /checkout/src/test/mir-opt/lower_intrinsics.discriminant.LowerIntrinsics.diff', src/tools/compiletest/src/runtest.rs:3516:25


failures:
    [mir-opt] src/test/mir-opt/lower_intrinsics.rs

@bors
Copy link
Contributor

bors commented Aug 31, 2022

💔 Test failed - checks-actions

@bors bors added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Aug 31, 2022
@davidtwco davidtwco removed the A-translation Area: Translation infrastructure, and migrating existing diagnostics to SessionDiagnostic label Oct 4, 2022
@matthiaskrgr matthiaskrgr deleted the rollup-85n2eel branch October 9, 2022 00:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
rollup A PR which is a rollup S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-libs Relevant to the library team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet