-
Notifications
You must be signed in to change notification settings - Fork 181
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
refine RustIrDatabase
interface
#241
Comments
First objection: The This method is used for three purposes:
|
Second objection: The This method is used to enumerate possible instantiations of auto traits where the self type is an unbounded inference variable; it's also used for some other kinds of internal goals, like |
I started the
I'm currently working through the impact of that rule. It makes some of the coherence related tests fail, but I'm not sure how important that is. If we take this step, though, we still don't quite reach the goal I wanted because of interactions with lazy normalization. See this comment for more details. |
Another concern: I think I would prefer to get away from removing "complex structs"...maybe? Not entirely sure about this. But it seems like it might be nice to have relatively "flat" methods, so that we can map more easily to whatever "HIR-like" data structures exist on the other side (and perhaps for better incremental tracking). |
@nikomatsakis The branch you linked doesn't contain anything related to this as far as I can see; is it the right one? Agree about both points;
Not sure how that would look... |
By the way, I actually need this for what I'm working on in RA currently -- I need to make every closure type implement the Fn traits, so I would need to find all closures in the whole crate or even project to satisfy the current interface. |
Also, I ran into the problem that in the process of inferring types for an |
Triage: this is what this issue needs to be closed. The idea is ,for example, rather than return an |
Actually, closing in favor of #506 |
This issue is for discussing the design of
RustIrDatabase
trait.The text was updated successfully, but these errors were encountered: