Closed
Description
The chalk integrate includes a is_coinductive
callback that indicates whether a particular goal is co-inductive:
rust/src/librustc_traits/chalk_context.rs
Lines 132 to 135 in e1643a8
A co-inductive goal is one of the following (see the corresponding chalk code for a kind of reference):
- proving whether an auto-trait is implemented
- "trait" well-formedness goals (not the type variant)
The existing trait solver doesn't have this notion of "well-formed trait goals" -- but it does have code related to testing about auto-traits that gives a few clues as to how to do the first step.