Make tcx.visibility() work for items in the local crate#77889
Make tcx.visibility() work for items in the local crate#77889jyn514 wants to merge 1 commit intorust-lang:masterfrom
tcx.visibility() work for items in the local crate#77889Conversation
|
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