Refactor is_uninhabited
We now cache the inhabitedness of types in the GlobalCtxt. Rather than calculating whether a type is visibly uninhabited from a given NodeId we calculate the full set of NodeIds from which a type is visibly uninhabited then cache that set. We can then use that to answer queries about the inhabitedness of a type relative to any given node.
Showing
src/librustc/ty/inhabitedness.rs
0 → 100644
想要评论请 注册 或 登录