Uh oh!
There was an error while loading. Please reload this page.
Fudge infer vars in the cause code of Obligation intentionally - #149299
Conversation
0e810ef to
c9e720dCompare
This comment has been minimized.
This comment has been minimized.
c9e720d to
a8e9638Compare| try_borrowing(cause.derived.parent_trait_pred, &[]) | ||
| // Parent trait predicate may contain regions that's already popped since `cause` | ||
| // in `Obligation` is ignored by folders/visitors. | ||
| // We can erase them since evaluation later doesn't care about regions anyway. |
There was a problem hiding this comment.
is that because the BestObligation folder happens inside of a fudge? and would eagerly fudging the cause there as well also avoid this ICE?
There was a problem hiding this comment.
It's because of the definition of Obligation. So the region vars in cause is ignored in fudge_inference_if_ok.
There was a problem hiding this comment.
yes, but the fudge when computing the best obligation could take (Predicate, Cause) as the return type instead of a full obligation to properly fudge the cause there
a8e9638 to
073e537CompareObligation intentionallyadwinwhite
commented
Nov 28, 2025
@rustbot ready |
ShoyuVanilla
commented
Nov 28, 2025
This fixes #142866 as well 👍 |
rustbot
commented
Nov 28, 2025
Some changes occurred to the core trait solver cc @rust-lang/initiative-trait-system-refactor |
lcnr
commented
Dec 1, 2025
@bors r+ rollup |
bors
commented
Dec 1, 2025
Rollup of 9 pull requests Successful merges: - #148690 (Implement `clamp_magnitude` method for primitive floats & signed integers) - #149102 (stabilize maybe_uninit_slice) - #149269 (cmse: do not calculate the layout of a type with infer types) - #149299 (Fudge infer vars in the cause code of `Obligation` intentionally) - #149344 (Don't suggest unwrap for Result in const) - #149358 (fix(parse): Limit frontmatter fences to 255 dashes ) - #149445 (make assoc fn inherit const stability from inherent `const impl` blocks) - #149479 (Fix indent in E0591.md) - #149496 (Fix#148889: Add label rib when visiting delegation body) r? `@ghost` `@rustbot` modify labels: rollup
Uh oh!
There was an error while loading. Please reload this page.
Rollup merge of #149299 - adwinwhite:next-245-ice, r=lcnr Fudge infer vars in the cause code of `Obligation` intentionally Fixes the ICE variant in rust-lang/trait-system-refactor-initiative#245. Fixes#142866. The detailed cause is in the test comments. r? `@lcnr`
Rollup of 9 pull requests Successful merges: - rust-lang/rust#148690 (Implement `clamp_magnitude` method for primitive floats & signed integers) - rust-lang/rust#149102 (stabilize maybe_uninit_slice) - rust-lang/rust#149269 (cmse: do not calculate the layout of a type with infer types) - rust-lang/rust#149299 (Fudge infer vars in the cause code of `Obligation` intentionally) - rust-lang/rust#149344 (Don't suggest unwrap for Result in const) - rust-lang/rust#149358 (fix(parse): Limit frontmatter fences to 255 dashes ) - rust-lang/rust#149445 (make assoc fn inherit const stability from inherent `const impl` blocks) - rust-lang/rust#149479 (Fix indent in E0591.md) - rust-lang/rust#149496 (Fixrust-lang/rust#148889: Add label rib when visiting delegation body) r? `@ghost` `@rustbot` modify labels: rollup
Fixes the ICE variant in rust-lang/trait-system-refactor-initiative#245.
Fixes#142866.
The detailed cause is in the test comments.
r? @lcnr