-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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 #101183
Rollup of 9 pull requests #101183
Conversation
These methods allow to cancel draining of unyielded elements.
and show some extra information when it happens in CTFE
Signed-off-by: Yuki Okushi <jtitor@2k36.org>
Signed-off-by: Yuki Okushi <jtitor@2k36.org>
Running with --bless causes the push to succeed if there are fixable formatting changes, but the changes don't make it into the push. We should have the user rerun with --bless (or x.py fmt) and commit the changes themselves (they might want to amend a particular commit, for instance).
This class was added to support the function signature [src] lockup. That lockup was changed in 34bd2b8 to use flexbox instead, leaving these selectors unused.
Signed-off-by: Alex Saveau <saveau.alexandre@gmail.com>
…lnay Add `vec::Drain{,Filter}::keep_rest` This PR adds `keep_rest` methods to `vec::Drain` and `vec::DrainFilter` under `drain_keep_rest` feature gate: ```rust // mod alloc::vec impl<T, A: Allocator> Drain<'_, T, A> { pub fn keep_rest(self); } impl<T, F, A: Allocator> DrainFilter<'_, T, F, A> where F: FnMut(&mut T) -> bool, { pub fn keep_rest(self); } ``` Both these methods cancel draining of elements that were not yet yielded from the iterators. While this needs more testing & documentation, I want at least start the discussion. This may be a potential way out of the "should `DrainFilter` exhaust itself on drop?" argument.
…i-obk Fall back when relating two opaques by substs in MIR typeck This is certainly _one_ way to fix rust-lang#100075. Not really confident it's the _best_ way to do it, though. The root cause of this issue is that during MIR type-check, we end up trying to equate an opaque against the same opaque def-id but with different substs. Because of the way that we replace RPITs during (HIR) typeck with an inference variable, we don't end up emitting a type-checking error, so the delayed MIR bug causes an ICE. See the `src/test/ui/impl-trait/issue-100075-2.rs` test below to make that clear -- in that example, we try to equate `{impl Sized} substs=[T]` and `{impl Sized} substs=[Option<T>]`, which causes an ICE. This new logic will instead cause us to infer `{impl Sized} substs=[Option<T>]` as the hidden type for `{impl Sized} substs=[T]`, which causes a proper error to be emitted later on when we check that an opaque isn't recursive. I'm open to closing this in favor of something else. Ideally we'd fix this in typeck, but the thing we do to ensure backwards compatibility with weird RPIT cases makes that difficult. Also open to discussing this further.
…gestion, r=cjgillot Suggest returning closure as `impl Fn` Fixes rust-lang#100936
…ckh726 Erase late bound regions before comparing types in `suggest_dereferences` Fixes rust-lang#101020
…oli-obk interpret: make read-pointer-as-bytes a CTFE-only error with extra information Next step in the reaction to rust-lang#99923. Also teaches Miri to implicitly strip provenance in more situations when transmuting pointers to integers, which fixes rust-lang/miri#2456. Pointer-to-int transmutation during CTFE now produces a message like this: ``` = help: this code performed an operation that depends on the underlying bytes representing a pointer = help: the absolute address of a pointer is not known at compile-time, so such operations are not supported ``` r? ``@oli-obk``
Remove `register_attr` feature Closes rust-lang#66080 Signed-off-by: Yuki Okushi <jtitor@2k36.org>
Don't --bless in pre-push hook Running with --bless causes the push to succeed if there are fixable formatting changes, but the changes don't make it into the push. We should have the user rerun with --bless (or x.py fmt) and commit the changes themselves (they might want to amend a particular commit, for instance).
…display, r=jsha rustdoc: remove unused CSS selectors for `.table-display` This class was added to support the function signature [src] lockup. That lockup was changed in 34bd2b8 to use flexbox instead, leaving these selectors unused. Continuation of rust-lang#101046
…KO8Ki Add another MaybeUninit array test with const This is another possible syntax and I just want to be absolutely sure it behaves correctly.
@bors r+ rollup=never p=5 |
☀️ Test successful - checks-actions |
📌 Perf builds for each rolled up PR: previous master: a0d07093f8 In the case of a perf regression, run the following command for each PR you suspect might be the cause: |
Finished benchmarking commit (0631ea5): comparison URL. Overall result: ❌ regressions - no action needed@rustbot label: -perf-regression Instruction countThis is a highly reliable metric that was used to determine the overall result at the top of this comment.
Max RSS (memory usage)ResultsThis is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.
CyclesResultsThis is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.
Footnotes |
Successful merges:
vec::Drain{,Filter}::keep_rest
#95376 (Addvec::Drain{,Filter}::keep_rest
)impl Fn
#101019 (Suggest returning closure asimpl Fn
)suggest_dereferences
#101022 (Erase late bound regions before comparing types insuggest_dereferences
)register_attr
feature #101123 (Removeregister_attr
feature).table-display
#101176 (rustdoc: remove unused CSS selectors for.table-display
)Failed merges:
r? @ghost
@rustbot modify labels: rollup
Create a similar rollup