Skip to content

Stop handling opaque types in queries and leave it to typeck#107891

Closed
oli-obk wants to merge 4 commits intorust-lang:masterfrom
oli-obk:tait_solver_decoupling
Closed

Stop handling opaque types in queries and leave it to typeck#107891
oli-obk wants to merge 4 commits intorust-lang:masterfrom
oli-obk:tait_solver_decoupling

Conversation

@oli-obk
Copy link
Contributor

@oli-obk oli-obk commented Feb 10, 2023

Some cleanups now that all the lazy TAIT work has settled down.

We do not need to look into queries anymore, as all the opaque types get "equated away" early enough so that the trait solvers don't see opaque types unless they should treat them opaquely.

The last commit additionally flips the default on infcx.at(...).eq and friends, requiring you to opt-in to registering hidden types. We can probably do more cleanups here and possibly manage to eliminate the InferCtxt::defining_use_anchor field entirely by doing all processing at the define_opaque_types sites.

r? @lcnr

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

Labels

perf-regression Performance regression. 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.

10 participants