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

Closed
wants to merge 30 commits into from

Conversation

matthiaskrgr
Copy link
Member

Successful merges:

Failed merges:

r? @ghost
@rustbot modify labels: rollup

Create a similar rollup

mejrs and others added 30 commits January 12, 2023 00:11
Parse `-> Ty | OtherTy`.
Parse type ascription in top level patterns.
…not `usize::from().unwrap_unchecked()`.

`usize::from()` gives a `usize`, not `Result<usize>`, and `usize: From<isize>` is not implemented.
…r=compiler-errors

Suggest coercion of `Result` using `?`

Fix rust-lang#47560.
…tic, r=WaffleLapkin

Suggest using a lock for `*Cell: Sync` bounds

I mostly did this for `OnceCell<T>` at first because users will be confused to see that the `OnceCell<T>` in `std` isn't `Sync` but then extended it to `Cell<T>` and `RefCell<T>` as well.
Teach parser to understand fake anonymous enum syntax

Parse `Ty | OtherTy` in function argument and return types.
Parse type ascription in top level patterns.

Minimally address rust-lang#100741.
…i-obk

Custom MIR: Support binary and unary operations

Lower binary and unary operations directly to corresponding unchecked MIR
operations. Ultimately this might not be syntax we want, but it allows for
experimentation in the meantime.

r? ``@oli-obk`` ``@JakobDegen``
…, r=albertlarsan68

Print PID holding bootstrap build lock on Linux

Partially address rust-lang#107077

Parse `/proc/locks` to find the PID of the process which created the build directory lock
…ush, r=estebank

Fix escaping inference var ICE in `point_at_expr_source_of_inferred_type`

Fixes rust-lang#107158

`point_at_expr_source_of_inferred_type` uses `lookup_probe` to adjust the self type of a method receiver -- but that method returns inference variables from inside a probe. That means that the ty vars are no longer valid, so we can't use any infcx methods on them.

Also, pass some extra span info to hack a quick solution to bad labels, resulting in this diagnostic improvement:

```rust
fn example2() {
    let mut x = vec![1];
    x.push("");
}
```

```diff
  error[E0308]: mismatched types
   --> src/main.rs:5:12
    |
  5 |     x.push("");
    |       ---- ^^
    |       |    |
    |       |    expected integer, found `&str`
-   |       |    this is of type `&'static str`, which causes `x` to be inferred as `Vec<{integer}>`
    |       arguments to this method are incorrect
```
(since that "which causes `x` to be inferred as `Vec<{integer}>` part is wrong)

r? `@estebank`

(we really should make this code better in general, cc rust-lang#106590, but that's a bit bigger issue that needs some more thinking about)
…apkin

`sub_ptr()` is equivalent to `usize::try_from().unwrap_unchecked()`, not `usize::from().unwrap_unchecked()`

`usize::from()` gives a `usize`, not `Result<usize>`, and `usize: From<isize>` is not implemented.
…mpiler-errors

`new_outside_solver` ->  `evaluate_root_goal`

r? `@rust-lang/initiative-trait-system-refactor`
@rustbot rustbot added A-translation Area: Translation infrastructure, and migrating existing diagnostics to SessionDiagnostic S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) 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. WG-trait-system-refactor The Rustc Trait System Refactor Initiative (-Znext-solver) rollup A PR which is a rollup labels Jan 23, 2023
@matthiaskrgr
Copy link
Member Author

@bors r+ rollup=never p=9

@bors
Copy link
Contributor

bors commented Jan 23, 2023

📌 Commit 7c055af has been approved by matthiaskrgr

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Jan 23, 2023
@bors
Copy link
Contributor

bors commented Jan 23, 2023

⌛ Testing commit 7c055af with merge 39d48f175517432f2db36f2f44b2172c65f56736...

@bors
Copy link
Contributor

bors commented Jan 23, 2023

💔 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 Jan 23, 2023
@clubby789
Copy link
Contributor

cfg-related warnings in #107086, updated with a fix

@rust-log-analyzer
Copy link
Collaborator

The job x86_64-msvc-1 failed! Check out the build log: (web) (plain)

Click to see the possible cause of the failure (guessed by this bot)
  |
9 | use std::fs::File;
  |     ^^^^^^^^^^^^^
  |
  = note: `-D unused-imports` implied by `-D warnings`

error: unused imports: `BufRead`, `BufReader`
   |
   |
10 | use std::io::{BufRead, BufReader};

error: unused variable: `f`
   --> bin/main.rs:128:19
    |
    |
128 | fn get_lock_owner(f: &std::path::Path) -> Option<u64> {
    |                   ^ help: if this is intentional, prefix it with an underscore: `_f`
    |
    = note: `-D unused-variables` implied by `-D warnings`
error: could not compile `bootstrap` due to 3 previous errors
warning: build failed, waiting for other jobs to finish...
failed to run: D:\a\rust\rust\build\x86_64-pc-windows-msvc\stage0\bin\cargo.exe build --manifest-path D:\a\rust\rust\src/bootstrap/Cargo.toml --locked --features build-metrics
Build completed unsuccessfully in 0:01:18
---
  |
9 | use std::fs::File;
  |     ^^^^^^^^^^^^^
  |
  = note: `-D unused-imports` implied by `-D warnings`

error: unused imports: `BufRead`, `BufReader`
   |
   |
10 | use std::io::{BufRead, BufReader};

error: unused variable: `f`
   --> bin/main.rs:128:19
    |
    |
128 | fn get_lock_owner(f: &std::path::Path) -> Option<u64> {
    |                   ^ help: if this is intentional, prefix it with an underscore: `_f`
    |
    = note: `-D unused-variables` implied by `-D warnings`
error: could not compile `bootstrap` due to 3 previous errors
failed to run: D:\a\rust\rust\build\x86_64-pc-windows-msvc\stage0\bin\cargo.exe build --manifest-path D:\a\rust\rust\src/bootstrap/Cargo.toml --locked --features build-metrics
Build completed unsuccessfully in 0:00:00
make: *** [Makefile:58: prepare] Error 1
---
  |
9 | use std::fs::File;
  |     ^^^^^^^^^^^^^
  |
  = note: `-D unused-imports` implied by `-D warnings`

error: unused imports: `BufRead`, `BufReader`
   |
   |
10 | use std::io::{BufRead, BufReader};

error: unused variable: `f`
   --> bin/main.rs:128:19
    |
    |
128 | fn get_lock_owner(f: &std::path::Path) -> Option<u64> {
    |                   ^ help: if this is intentional, prefix it with an underscore: `_f`
    |
    = note: `-D unused-variables` implied by `-D warnings`
error: could not compile `bootstrap` due to 3 previous errors
failed to run: D:\a\rust\rust\build\x86_64-pc-windows-msvc\stage0\bin\cargo.exe build --manifest-path D:\a\rust\rust\src/bootstrap/Cargo.toml --locked --features build-metrics
Build completed unsuccessfully in 0:00:00
make: *** [Makefile:58: prepare] Error 1
---
  |
9 | use std::fs::File;
  |     ^^^^^^^^^^^^^
  |
  = note: `-D unused-imports` implied by `-D warnings`

error: unused imports: `BufRead`, `BufReader`
   |
   |
10 | use std::io::{BufRead, BufReader};

error: unused variable: `f`
   --> bin/main.rs:128:19
    |
    |
128 | fn get_lock_owner(f: &std::path::Path) -> Option<u64> {
    |                   ^ help: if this is intentional, prefix it with an underscore: `_f`
    |
    = note: `-D unused-variables` implied by `-D warnings`
error: could not compile `bootstrap` due to 3 previous errors
failed to run: D:\a\rust\rust\build\x86_64-pc-windows-msvc\stage0\bin\cargo.exe build --manifest-path D:\a\rust\rust\src/bootstrap/Cargo.toml --locked --features build-metrics
Build completed unsuccessfully in 0:00:00
make: *** [Makefile:58: prepare] Error 1
---
  |
9 | use std::fs::File;
  |     ^^^^^^^^^^^^^
  |
  = note: `-D unused-imports` implied by `-D warnings`

error: unused imports: `BufRead`, `BufReader`
   |
   |
10 | use std::io::{BufRead, BufReader};

error: unused variable: `f`
   --> bin/main.rs:128:19
    |
    |
128 | fn get_lock_owner(f: &std::path::Path) -> Option<u64> {
    |                   ^ help: if this is intentional, prefix it with an underscore: `_f`
    |
    = note: `-D unused-variables` implied by `-D warnings`
error: could not compile `bootstrap` due to 3 previous errors
failed to run: D:\a\rust\rust\build\x86_64-pc-windows-msvc\stage0\bin\cargo.exe build --manifest-path D:\a\rust\rust\src/bootstrap/Cargo.toml --locked --features build-metrics
Build completed unsuccessfully in 0:00:00
make: *** [Makefile:58: prepare] Error 1

@Dylan-DPC Dylan-DPC closed this Jan 24, 2023
@matthiaskrgr matthiaskrgr deleted the rollup-d31q0q6 branch March 16, 2024 18:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-translation Area: Translation infrastructure, and migrating existing diagnostics to SessionDiagnostic rollup A PR which is a rollup S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) 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. WG-trait-system-refactor The Rustc Trait System Refactor Initiative (-Znext-solver)
Projects
None yet
Development

Successfully merging this pull request may close these issues.