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

Closed
wants to merge 25 commits into from

Conversation

workingjubilee
Copy link
Member

Successful merges:

Failed merges:

r? @ghost
@rustbot modify labels: rollup

Create a similar rollup

compiler-errors and others added 25 commits August 22, 2024 14:22
In the implementation of `force_mut`, I chose performance over safety.
For `LazyLock` this isn't really a choice; the code has to be unsafe.
But for `LazyCell`, we can have a full-safe implementation, but it will
be a bit less performant, so I went with the unsafe approach.
When we have two types with the same name, one without type parameters and the other with type parameters and a derive macro, we were before incorrectly suggesting to remove type parameters from the former, which ICEd because we were suggesting to remove nothing. We now gate against this.

The output is still not perfect. E0107 should explicitly detect this case and provide better context, but for now let's avoid the ICE.
This is ignored by LLVM, but is still incorrect.
The previous name is just an LLVMism, which conveys almost nothing about
what is actually meant by the function relative to the ABI.

In doing so, remove an already-addressed FIXME.
Add `Thread::{into_raw, from_raw}`

Public API:
```rust
#![unstable(feature = "thread_raw", issue = "97523")]

impl Thread {
    pub fn into_raw(self) -> *const ();
    pub unsafe fn from_raw(ptr: *const ()) -> Thread;
}
```

ACP: rust-lang/libs-team#200
Do not ICE with incorrect empty suggestion

When we have two types with the same name, one without type parameters and the other with type parameters and a derive macro, we were before incorrectly suggesting to remove type parameters from the former, which ICEd because we were suggesting to remove nothing. We now gate against this.

The output is still not perfect. E0107 should explicitly detect this case and provide better context, but for now let's avoid the ICE.

Fix rust-lang#108748.
Gate `repr(Rust)` correctly on non-ADT items

rust-lang#114201 added `repr(Rust)` but didn't add any attribute validation to it like `repr(C)` has, to only allow it on ADT items.

I consider this code to be nonsense, for example:
```
#[repr(Rust)]
fn foo() {}
```

Reminder that it's different from `extern "Rust"`, which *is* valid on function items. But also this now disallows `repr(Rust)` on modules, impls, traits, etc.

I'll crater it, if it looks bad then I'll add an FCW.

---

https://github.com/rust-lang/rust/labels/relnotes: Compatibility (minor breaking change).
…nieu

Win: Open dir for sync access in remove_dir_all

A small follow up to rust-lang#129800.

We should explicitly open directories for synchronous access. We ultimately use `GetFileInformationByHandleEx` to read directories which should paper over any issues caused by using async directory reads (or else return an error) but it's better to do the right thing in the first place. Note though that `delete` does not read or write any data so it's not necessary there.
…irect, r=bjorn3

Reduce confusion about `make_indirect_byval` by renaming it

As part of doing so, remove the incorrect handling of the wasm target's `make_indirect_byval` (i.e. using it at all).
…ake-2, r=Amanieu

Implement ACP 429: add `Lazy{Cell,Lock}::get[_mut]` and `force_mut`

Tracking issue for `lazy_get`: rust-lang#129333
Update the minimum external LLVM to 18

With this change, we'll have stable support for LLVM 18 and 19.
For reference, the previous increase to LLVM 17 was rust-lang#122649.

cc `@rust-lang/wg-llvm`
r? nikic
…cuviper

Clarify docs for std::fs::File::write

This PR fixes the doc comment for `std::fs::File::write` method.
…hs, r=compiler-errors

[Clippy] Swap `manual_retain` to use diagnostic items instead of paths

Part of rust-lang/rust-clippy#5393, just a chore.
@rustbot rustbot added A-run-make Area: port run-make Makefiles to rmake.rs A-testsuite Area: The testsuite used to check the correctness of rustc O-windows Operating system: Windows 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) labels Sep 18, 2024
@rustbot rustbot added T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-infra Relevant to the infrastructure 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 Sep 18, 2024
@workingjubilee
Copy link
Member Author

@bors r+ p=9 rollup=never

@bors
Copy link
Contributor

bors commented Sep 18, 2024

📌 Commit 457c91c has been approved by workingjubilee

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 Sep 18, 2024
@bors
Copy link
Contributor

bors commented Sep 18, 2024

🔒 Merge conflict

This pull request and the master branch diverged in a way that cannot be automatically merged. Please rebase on top of the latest master branch, and let the reviewer approve again.

How do I rebase?

Assuming self is your fork and upstream is this repository, you can resolve the conflict following these steps:

  1. git checkout rollup-fik4g5u (switch to your branch)
  2. git fetch upstream master (retrieve the latest master)
  3. git rebase upstream/master -p (rebase on top of it)
  4. Follow the on-screen instruction to resolve conflicts (check git status if you got lost).
  5. git push self rollup-fik4g5u --force-with-lease (update this PR)

You may also read Git Rebasing to Resolve Conflicts by Drew Blessing for a short tutorial.

Please avoid the "Resolve conflicts" button on GitHub. It uses git merge instead of git rebase which makes the PR commit history more difficult to read.

Sometimes step 4 will complete without asking for resolution. This is usually due to difference between how Cargo.lock conflict is handled during merge and rebase. This is normal, and you should still perform step 5 to update this PR.

Error message
Removing tests/ui/asm/inline-syntax.arm_llvm_18.stderr
Removing src/ci/docker/host-x86_64/x86_64-gnu-llvm-17/Dockerfile
Auto-merging compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp
CONFLICT (content): Merge conflict in compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp
Auto-merging compiler/rustc_codegen_llvm/src/context.rs
Auto-merging compiler/rustc_codegen_llvm/src/builder.rs
Auto-merging compiler/rustc_codegen_llvm/src/abi.rs
Automatic merge failed; fix conflicts and then commit the result.

@bors bors added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Sep 18, 2024
@cuviper
Copy link
Member

cuviper commented Sep 18, 2024

I rebased #130487 for that conflict.

@workingjubilee
Copy link
Member Author

Ah.
@bors r-

@workingjubilee workingjubilee deleted the rollup-fik4g5u branch September 18, 2024 21:31
@bors
Copy link
Contributor

bors commented Sep 18, 2024

☔ The latest upstream changes (presumably #130519) made this pull request unmergeable. Please resolve the merge conflicts.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-run-make Area: port run-make Makefiles to rmake.rs A-testsuite Area: The testsuite used to check the correctness of rustc O-windows Operating system: Windows rollup A PR which is a rollup S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. 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-infra Relevant to the infrastructure 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.