Skip to content

Conversation

@adwinwhite
Copy link
Contributor

@adwinwhite adwinwhite commented Nov 14, 2025

First step for param_env normalization future compat warning. zulip thread

I didn't put the check directly in param_env query because normalize_param_env_or_error has some adjustments on the predicates: elaboration and outlive predicates manipulation. I'd have to replicate these in param_env to compare normalized predicates properly.
The downside of putting the check inside normalize_param_env_or_error is that it's used in more than param_env query. It's also used in compare_impl_item and several other places. I'm not sure if this is desired.

I didn't bless tests since the hard error will be changed to lint later.
Blessed tests to demonstrate the changes.

And there's one test about const generics I don't know how to fix.
Canonicalizer for the next solver will replace ParamConst with PlaceholderConst, but it still uses the same try_evaluate_const internally and process_obligation doesn't like PlaceholderConst.

r? @lcnr

@rustbot
Copy link
Collaborator

rustbot commented Nov 14, 2025

Some changes occurred to the core trait solver

cc @rust-lang/initiative-trait-system-refactor

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. WG-trait-system-refactor The Rustc Trait System Refactor Initiative (-Znext-solver) labels Nov 14, 2025
@rust-log-analyzer

This comment has been minimized.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. WG-trait-system-refactor The Rustc Trait System Refactor Initiative (-Znext-solver)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants