Skip to content

Rollup of 4 pull requests - #129242

Closed
jieyouxu wants to merge 8 commits into
rust-lang:masterfrom
jieyouxu:rollup-1yhzl81
Closed

Rollup of 4 pull requests#129242
jieyouxu wants to merge 8 commits into
rust-lang:masterfrom
jieyouxu:rollup-1yhzl81

Conversation

@jieyouxu

Copy link
Copy Markdown
Member

Successful merges:

r? @ghost
@rustbot modify labels: rollup

Create a similar rollup

surechenand others added 8 commits July 23, 2024 10:24
For following:
```rust
struct A;
impl A {
fn test4(&self) {
let mut _file = File::create("foo.txt")?;
//~^ ERROR the `?` operator can only be used in a method
}
```
Suggest:
```rust
impl A {
fn test4(&self) -> Result<(), Box<dyn std::error::Error>> {
let mut _file = File::create("foo.txt")?;
//~^ ERROR the `?` operator can only be used in a method
Ok(())
}
}
```
For rust-lang#125997
Fixesrust-lang#126831.
Without this patch, type normalization is not always idempotent, which
leads to all sorts of bugs in places that assume that normalizing a
normalized type does nothing.
... by using `std::fs::remove_dir_all`, which handles a bunch of edge
cases including read-only files and symlinks which are extremely tricky
on Windows.
Suggest adding Result return type for associated method in E0277.
Recommit rust-lang#126515 because I messed up during rebase,
Suggest adding Result return type for associated method in E0277.
For following:
```rust
struct A;
impl A {
fn test4(&self) {
let mut _file = File::create("foo.txt")?;
//~^ ERROR the `?` operator can only be used in a method
}
```
Suggest:
```rust
impl A {
fn test4(&self) -> Result<(), Box<dyn std::error::Error>> {
let mut _file = File::create("foo.txt")?;
//~^ ERROR the `?` operator can only be used in a method
Ok(())
}
}
```
For rust-lang#125997
r? ``@cjgillot``
…links, r=Kobzol
bootstrap: fix clean's remove_dir_all implementation
It turns out bootstrap's `clean.rs`'s hand-rolled `rm_rf` (which probably comes before `std::fs::remove_dir_all` was stable) is very broken on native Windows around both read-only files/directories and especially symbolic links. So instead of rolling our own, just use `std::fs::remove_dir_all`.
This is a blocker for compiletest's own `rm_rf` implementation rust-lang#129155 which happens to be also buggy, which in turn is a blocker for the rmake.rs test port rust-lang#128562 that heavily exercises symlinks (I was reviewing rust-lang#128562 and testing it on native Windows which is how I found out).
I also left a FIXME for `detect_src_and_out` due to a failing assertion on native Windows (opened rust-lang#129188):
```
---- core::config::tests::detect_src_and_out stdout ----
thread 'core::config::tests::detect_src_and_out' panicked at src\core\config\tests.rs:72:13:
assertion `left == right` failed
left: "E:\\tmp"
right: "C:\\tmp"
```
Fixesrust-lang#112544 (because now we handle Windows symlinks properly).
try-job: x86_64-msvc
try-job: i686-mingw
try-job: test-various
try-job: armhf-gnu
try-job: aarch64-apple
try-job: aarch64-gnu
Fix order of normalization and recursion in const folding.
Fixesrust-lang#126831.
Without this patch, type normalization is not always idempotent, which leads to all sorts of bugs in places that assume that normalizing a normalized type does nothing.
Tracking issue: rust-lang#95174
r? BoxyUwU
@rustbotrustbot added 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. rollup A PR which is a rollup labels Aug 18, 2024
@jieyouxu

Copy link
Copy Markdown
MemberAuthor

@bors r+ rollup=never p=4

@bors

bors commented Aug 18, 2024

Copy link
Copy Markdown
Collaborator

📌 Commit 2e243da has been approved by jieyouxu

It is now in the queue for this repository.

@borsbors 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 Aug 18, 2024
@bors

bors commented Aug 18, 2024

Copy link
Copy Markdown
Collaborator

⌛ Testing commit 2e243da with merge 88a596a...

bors added a commit to rust-lang-ci/rust that referenced this pull request Aug 18, 2024
Rollup of 4 pull requests
Successful merges:
- rust-lang#128084 (Suggest adding Result return type for associated method in E0277.)
- rust-lang#129187 (bootstrap: fix clean's remove_dir_all implementation)
- rust-lang#129208 (Fix order of normalization and recursion in const folding.)
- rust-lang#129228 (crashes: more tests)
r? `@ghost`
`@rustbot` modify labels: rollup
@rust-log-analyzer

Copy link
Copy Markdown
Collaborator

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

Click to see the possible cause of the failure (guessed by this bot)
test [crashes] tests\crashes\129166.rs ... ok
test [crashes] tests\crashes\129205.rs ... ok
test [crashes] tests\crashes\129127.rs ... ok
test [crashes] tests\crashes\129150.rs ... ok
2024-08-18T19:08:55.083183Z ERROR compiletest::runtest: fatal error, panic: "crashtest no longer crashes/triggers ICE, horray! Please give it a meaningful name, add a doc-comment to the start of the test explaining why it exists and move it to tests/ui or wherever you see fit. Adding 'Fixes #<issueNr>' to your PR description ensures that the corresponding ticket is auto-closed upon merge."
test [crashes] tests\crashes\129209.rs ... ok
test [crashes] tests\crashes\129219.rs ... ok
test [crashes] tests\crashes\129214.rs ... ok
test [crashes] tests\crashes\34127.rs ... ok
---
failures:
---- [crashes] tests\crashes\129216.rs stdout ----
error: crashtest no longer crashes/triggers ICE, horray! Please give it a meaningful name, add a doc-comment to the start of the test explaining why it exists and move it to tests/ui or wherever you see fit. Adding 'Fixes #<issueNr>' to your PR description ensures that the corresponding ticket is auto-closed upon merge.
thread '[crashes] tests\crashes\129216.rs' panicked at src\tools\compiletest\src\runtest.rs:368:18:
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
failures:
failures:
[crashes] tests\crashes\129216.rs
test result: FAILED. 231 passed; 1 failed; 0 ignored; 0 measured; 0 filtered out; finished in 6.98s
Some tests failed in compiletest suite=crashes mode=crashes host=x86_64-pc-windows-msvc target=x86_64-pc-windows-msvc
Build completed unsuccessfully in 0:42:53
make: *** [Makefile:102: ci-msvc-ps1] Error 1
network time: Sun, 18 Aug 2024 19:08:58 GMT
##[error]Process completed with exit code 2.
Post job cleanup.
[command]"C:\Program Files\Git\bin\git.exe" version

@bors

bors commented Aug 18, 2024

Copy link
Copy Markdown
Collaborator

💔 Test failed - checks-actions

@borsbors 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 18, 2024
@jieyouxu
jieyouxu deleted the rollup-1yhzl81 branch August 19, 2024 04:38
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

rollupA PR which is a rollupS-waiting-on-reviewStatus: Awaiting review from the assignee but also interested parties.T-bootstrapRelevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)T-compilerRelevant 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.

7 participants

@jieyouxu@bors@rust-log-analyzer@matthiaskrgr@rustbot@surechen@veluca93