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

Closed
wants to merge 14 commits into from
Closed

Conversation

Dylan-DPC
Copy link
Member

Successful merges:

Failed merges:

r? @ghost
@rustbot modify labels: rollup

Create a similar rollup

tmiasko and others added 14 commits February 17, 2022 16:51
fix a message

implement a rustfix-applicable suggestion

implement `suggest_floating_point_literal`

add `ObligationCauseCode::BinOp`

remove duplicate code

fix function names in uitests
…used type parameter

The user wrote the bound, so it's obvious they want a type.
…const-with-bounds-unused-generic-param, r=jackh726

Do not suggest using a const parameter when there are bounds on an unused type parameter

The user wrote the bound, so it's obvious they want a type.
…ackh726

Provide extra note if synthetic type args are specified

Implement the unresolved question in rust-lang#83701 as suggested in rust-lang#86176 (comment).

r? `@jackh726`
…loat-divided-by-integer, r=estebank

Suggest a float literal when dividing a floating-point type by `{integer}`

closes rust-lang#93829
…=jackh726

Remove unused `unsound_ignore_borrow_on_drop`
…r=jackh726

chalk: Fix wrong debrujin index in opaque type handling.

A folder in opaque type lowering was substituting all opaque type references with a variable with debrujin index 0 ignoring how many binders deep we are.

This caused an ICE with `Not enough bound vars: ^0 not found in []` ([full logs](https://gist.github.com/Dirbaio/2b9374ff4fce37afb9d665dc9f0000df)) with the following code.

```rust
fn main() -> () {}
async fn foo(x: u32) -> u32 {
    x
}
```

With the fix, it no longer ICEs. It still doesn't typecheck due to generator issues. I've added a "known-bug" test so that at least it doesn't regress back to ICEing.

r? `@jackh726`
Avoid exhausting stack space in dominator compression

Doesn't add a test case -- I ended up running into this while playing with the generated example from rust-lang#43578, which we could do with a run-make test (to avoid checking a large code snippet into tree), but I suspect we don't want to wait for it to compile (locally it takes ~14s -- not terrible, but doesn't seem worth it to me). In practice stack space exhaustion is difficult to test for, too, since if we set the bound too low a different call structure above us (e.g., a nearer ensure_sufficient_stack call) would let the test pass even with the old impl, most likely.

Locally it seems like this manages to perform approximately equivalently to the recursion, but will run perf to confirm.
@rustbot rustbot added T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. rollup A PR which is a rollup labels Feb 26, 2022
@Dylan-DPC
Copy link
Member Author

@bors r+ rollup=never p=5

@bors
Copy link
Contributor

bors commented Feb 26, 2022

📌 Commit eef67b4 has been approved by Dylan-DPC

@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 Feb 26, 2022
@rust-log-analyzer
Copy link
Collaborator

The job mingw-check failed! Check out the build log: (web) (plain)

Click to see the possible cause of the failure (guessed by this bot)
    Checking rustc_save_analysis v0.0.0 (/checkout/compiler/rustc_save_analysis)
    Checking rustc_codegen_ssa v0.0.0 (/checkout/compiler/rustc_codegen_ssa)
    Checking rustc_resolve v0.0.0 (/checkout/compiler/rustc_resolve)
    Checking rustc_trait_selection v0.0.0 (/checkout/compiler/rustc_trait_selection)
error[E0107]: this struct takes 1 generic argument but 0 generic arguments were supplied
   --> compiler/rustc_trait_selection/src/traits/error_reporting/suggestions.rs:181:19
181 |         err: &mut DiagnosticBuilder<'_>,
    |                   ^^^^^^^^^^^^^^^^^ expected 1 generic argument
    |
    |
note: struct defined here, with 1 generic parameter: `G`
    |
    |
19  | pub struct DiagnosticBuilder<'a, G: EmissionGuarantee> {
help: add missing generic argument
    |
    |
181 |         err: &mut DiagnosticBuilder<'_, G>,


error[E0107]: this struct takes 1 generic argument but 0 generic arguments were supplied
    --> compiler/rustc_trait_selection/src/traits/error_reporting/suggestions.rs:2512:19
2512 |         err: &mut DiagnosticBuilder<'_>,
     |                   ^^^^^^^^^^^^^^^^^ expected 1 generic argument
     |
     |
note: struct defined here, with 1 generic parameter: `G`
     |
     |
19   | pub struct DiagnosticBuilder<'a, G: EmissionGuarantee> {
help: add missing generic argument
     |
     |
2512 |         err: &mut DiagnosticBuilder<'_, G>,

For more information about this error, try `rustc --explain E0107`.
error: could not compile `rustc_trait_selection` due to 2 previous errors
warning: build failed, waiting for other jobs to finish...

@matthiaskrgr
Copy link
Member

#94078 got an update, rollup fails in ci

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-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.