Remove deferred sized checks (make them eager)#100652
Merged
bors merged 1 commit intorust-lang:masterfrom Aug 17, 2022
Merged
Conversation
Contributor
|
r? @TaKO8Ki (rust-highfive has picked a reviewer for you, use r? to override) |
compiler-errors
commented
Aug 16, 2022
Contributor
Author
There was a problem hiding this comment.
This can be followed up later
6a04da4 to
33212bf
Compare
compiler-errors
commented
Aug 16, 2022
| self.normalize_associated_types_in(span, input), | ||
| span, | ||
| traits::SizedArgumentType(None), | ||
| traits::SizedArgumentType(arg_span), |
Contributor
Author
There was a problem hiding this comment.
This is a somewhat unrelated fix, but it improves spans as well I think.
Member
|
@bors r+ rollup |
Collaborator
matthiaskrgr
added a commit
to matthiaskrgr/rust
that referenced
this pull request
Aug 17, 2022
…cks, r=TaKO8Ki
Remove deferred sized checks (make them eager)
Improves diagnostics spans... this doesn't seem to be the case anymore:
```rust
// Some additional `Sized` obligations badly affect type inference.
// These obligations are added in a later stage of typeck.
pub(super) deferred_sized_obligations:
RefCell<Vec<(Ty<'tcx>, Span, traits::ObligationCauseCode<'tcx>)>>,
```
bors
added a commit
to rust-lang-ci/rust
that referenced
this pull request
Aug 17, 2022
…iaskrgr Rollup of 15 pull requests Successful merges: - rust-lang#99474 (Rustdoc json tests: New `@hasexact` test command) - rust-lang#99972 (interpret: only consider 1-ZST when searching for receiver) - rust-lang#100018 (Clean up `LitKind`) - rust-lang#100379 (triagebot: add translation-related mention groups) - rust-lang#100389 (Do not report cycle error when inferring return type for suggestion) - rust-lang#100489 (`is_knowable` use `Result` instead of `Option`) - rust-lang#100532 (unwind: don't build dependency when building for Miri) - rust-lang#100608 (needless separation of impl blocks) - rust-lang#100621 (Pass +atomics-32 feature for {arm,thumb}v4t-none-eabi) - rust-lang#100646 (Migrate emoji identifier diagnostics to `SessionDiagnostic` in rustc_interface) - rust-lang#100652 (Remove deferred sized checks (make them eager)) - rust-lang#100655 (Update books) - rust-lang#100656 (Update cargo) - rust-lang#100660 (Fixed a few documentation errors) - rust-lang#100661 (Fixed a few documentation errors) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
Contributor
|
Hey @compiler-errors , it seems like this PR might have caused some performance regressions, based on this comment from the rollup PR: The main benefit of this PR is improvements to the diagnostics, right? I'm trying to figure out whether the tradeoff works out here. |
Contributor
|
@rustbot label: +perf-regression |
This was referenced Aug 25, 2022
bors
added a commit
to rust-lang-ci/rust
that referenced
this pull request
Sep 3, 2022
…ed-sized-checks, r=pnkfelix Revert "Remove deferred sized checks" cc: rust-lang#100652 (comment) I'm okay with reverting this for now, and I will look into the diagnostic regressions. This reverts commit 33212bf. r? `@pnkfelix` ---- EDIT: This _also_ fixes rust-lang#101066, a regression in method selection logic/coercion(?) due to the early registering of a `Sized` bound.
RalfJung
pushed a commit
to RalfJung/rust-analyzer
that referenced
this pull request
Apr 20, 2024
…checks, r=pnkfelix Revert "Remove deferred sized checks" cc: rust-lang/rust#100652 (comment) I'm okay with reverting this for now, and I will look into the diagnostic regressions. This reverts commit 33212bf. r? `@pnkfelix` ---- EDIT: This _also_ fixes #101066, a regression in method selection logic/coercion(?) due to the early registering of a `Sized` bound.
RalfJung
pushed a commit
to RalfJung/rust-analyzer
that referenced
this pull request
Apr 27, 2024
…checks, r=pnkfelix Revert "Remove deferred sized checks" cc: rust-lang/rust#100652 (comment) I'm okay with reverting this for now, and I will look into the diagnostic regressions. This reverts commit 33212bf. r? `@pnkfelix` ---- EDIT: This _also_ fixes #101066, a regression in method selection logic/coercion(?) due to the early registering of a `Sized` bound.
Kobzol
pushed a commit
to Kobzol/portable-simd
that referenced
this pull request
Feb 3, 2026
…checks, r=pnkfelix Revert "Remove deferred sized checks" cc: rust-lang/rust#100652 (comment) I'm okay with reverting this for now, and I will look into the diagnostic regressions. This reverts commit 33212bf7f527798a8cfa2bbb38781742f4ca718a. r? `@pnkfelix` ---- EDIT: This _also_ fixes #101066, a regression in method selection logic/coercion(?) due to the early registering of a `Sized` bound.
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.
Improves diagnostics spans... this doesn't seem to be the case anymore: