-
Notifications
You must be signed in to change notification settings - Fork 12.9k
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
Make tcx.visibility()
work for items in the local crate
#77889
Conversation
The important commit is 3a88f79, the first one just switches lots of places from
I don't know how to handle these. |
@jyn514 Touching |
3a88f79
to
f357bc8
Compare
f357bc8
to
ee82695
Compare
tcx.visibility()
work for items in the local cratetcx.visibility()
work for items in the local crate
I think I did it right this time :) It passes |
ee82695
to
ca356c2
Compare
This also changes rustc_metadata to use `tcx.visibility()` for `record!`ing metadata.
ca356c2
to
ceb2e03
Compare
Let me know if I should switch more places to using |
So I ended up fixing this properly and deduplicating visibility calculations in all three places in which they are performed - resolve (which can't use queries), metadata encoding, and privacy. I'm still debugging, but if I finish that work today or at least tomorrow, I'll close this PR in favor of it. |
Closing in favor of #78077. |
This also changes rustc_metadata to use
tcx.visibility()
forrecord!
ing metadata.See #77820 (comment) for the history.
r? @petrochenkov