Repository navigation
Rollup of 13 pull requests - #165403
Closed
JonathanBrouwer wants to merge 37 commits into
Closed
Rollup of 13 pull requests#165403JonathanBrouwer wants to merge 37 commits into
JonathanBrouwer wants to merge 37 commits into
Conversation
OpenBSD added getexecpath(3) to libc, which returns an already-canonicalized executable path directly. Replace the sysctl(KERN_PROC_ARGV)-based implementation. This was the last user of div_exact in std, so drop the exact_div feature gate.
…poll impl instead of the desugared creator function.
It is already rejected on such functions, and keeping it only produced a redundant 'incompatible with #[cold]' error.
…being allowed Upstream no longer rejects the combination, so replace the UI test expecting that error with a codegen test checking that the body coroutine still inherits the target features.
…cdylib test: - Add `sys::thread_local::guard::aix` using `__pt_atexit_np` to run main thread TLS destructors on process exit on AIX. - Update `dynamic-loading-cdylib` to use member archive syntax (`RTLD_MEMBER`) for `dlopen` on AIX. - Replace the mode array in `dynamic-loading-cdylib` with a `COMMAND_ARGS` constant that selects `load_only` for musl and AIX because `dlclose` does not invoke TLS destructors on those platforms.
A comment against PR 151817 mentioned that the test file added in this PR kept causing "arbitrary" test file changes. This is because one line of the expanded output sits *just* at 78 columns, which is the pretty-printer's margin. Adding or removing a symbol shifts every index after it, and when one of those gains or loses a digit, the wrapping moves. We cannot use `normalize-stdout` as the layout is decided before normalization runs. We fix this by avoiding a strict golden comparison, and instead using a regex to directly test that the expected syntax contexts exist in the expanded output.
* Add regression test against rigidity assertion * Make non-rigid types equal to one another on error reporting * Bless errors after rigid treatment change * Remove previously useful crash test! * Add suggested comments from code review
…ttr, r=saethlin
Make inline attributes apply to the generated `poll` in async fn
This PR adds lowering code (similar to how track_caller forwarding works) to `async fn` items and `async ||` closures such that any inline attributes put on them are inherited by the generated coroutine (corresponding to the `poll()` implementation) and are not applied to the outer function. This behavior matches the accepted FCP in the first linked issue.
Code like the following now correctly codegen 3 functions
- `async_fn_test::consumer`
- `async_fn_test::hi::{closure#0}`
- `core::ptr::drop_in_place::<async_fn_test::hi::{closure#0}>`
```rust
#[inline(never)]
pub async fn hi() -> i32 {
1337
}
pub fn consumer(cx: &mut Context<'_>) -> Option<i32> {
let fut = hi();
let pinned = pin!(fut);
match pinned.poll(cx) {
Poll::Ready(value) => Some(value),
Poll::Pending => None,
}
}
```
Fixes rust-lang#129347 and fixes rust-lang#106765.
This has already been FCP'ed here: rust-lang#129347
[perf] Reuse CanonicalVarKinds if no new variables were added Have seen a perf improvement locally. The idea is to reuse the output of `mk_canonical_var_kinds` if `self.state.var_kinds` is unchanged
…=lcnr Avoid building a region map when erasing bound regions In `instantiate_bound_regions_with_erased`, a closure always returns `self.lifetimes.re_erased`, so cache map that `instantiate_bound_regions` creates is unnecessary here. https://github.com/rust-lang/rust/blob/09026e0fcc8e3c31697db6ce158d8ff8b7df52d0/compiler/rustc_middle/src/ty/fold.rs#L64-L78
…hnTitor std: Use getexecpath() for current_exe() on OpenBSD OpenBSD added getexecpath(3) to libc, which returns an already-canonicalized executable path directly. Replace the sysctl(KERN_PROC_ARGV)-based implementation. This was the last user of div_exact in std, so drop the exact_div feature gate.
…r=GuillaumeGomez Reenable some cg_gcc tests that were disabled
…rtdev Don't use `llvm_type` as the type of `static`s. This PR replaces the two uses of `llvm_type` as the type of `static`s - only the size of the static matters, so `cx.type_array(cx.type_i8(), layout.size)` is sufficient. As `static`s have to be redefined if the initialiser type is not the same as the existing type. using an LLVM `i8` array here is more optimal as it means the static type already matches the initializer in cases where the initializer is just plain bytes. r? @folkertdev
Member
Author
|
@bors r+ p=5 force |
Contributor
This comment has been minimized.
This comment has been minimized.
rust-bors Bot
pushed a commit
that referenced
this pull request
Nov 3, 2026
…uwer Rollup of 13 pull requests Successful merges: - #149245 (Make inline attributes apply to the generated `poll` in async fn) - #164304 ([perf] Reuse CanonicalVarKinds if no new variables were added) - #165109 (Avoid building a region map when erasing bound regions) - #163393 (std: Use getexecpath() for current_exe() on OpenBSD) - #165358 (Reenable some cg_gcc tests that were disabled) - #165371 (Don't use `llvm_type` as the type of `static`s.) - #162232 (Replace `builtin #` with `k#`) - #162608 (Avoid oscillating line wrapping due to symbol indices) - #164241 (make the safety documentation consistent in Ptr module) - #165029 (Use `MalformedLintAttributeInput` in more places) - #165203 (AIX: Implement TLS destructor guard in std and update dynamic-loading-cdylib test) - #165230 (Fix rigidity assertion ICE) - #165374 (Refactorings in preparation for the move trait)
Collaborator
|
The job Click to see the possible cause of the failure (guessed by this bot) |
Contributor
|
💔 Test for 44ff722 failed: CI. Failed job:
|
Contributor
|
PR #162232, which is a member of this rollup, was unapproved. |
Contributor
|
PR #165371, which is a member of this rollup, was unapproved. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Successful merges:
pollin async fn #149245 (Make inline attributes apply to the generatedpollin async fn)llvm_typeas the type ofstatics. #165371 (Don't usellvm_typeas the type ofstatics.)builtin #withk##162232 (Replacebuiltin #withk#)MalformedLintAttributeInputin more places #165029 (UseMalformedLintAttributeInputin more places)r? @ghost
Create a similar rollup