pub struct ErasedReachability { /* private fields */ }Expand description
A reachability tracker for erased expressions.
Implementations§
Source§impl ErasedReachability
impl ErasedReachability
Sourcepub fn mark_reachable(&mut self, name: &str)
pub fn mark_reachable(&mut self, name: &str)
Mark a constant as reachable.
Sourcepub fn is_reachable(&self, name: &str) -> bool
pub fn is_reachable(&self, name: &str) -> bool
Return whether a constant is reachable.
Sourcepub fn reachable_names(&self) -> &[String]
pub fn reachable_names(&self) -> &[String]
Return all reachable names.
Sourcepub fn reachable_count(&self) -> usize
pub fn reachable_count(&self) -> usize
Return the number of reachable declarations.
Sourcepub fn analyze_module(&mut self, module: &ErasedModule)
pub fn analyze_module(&mut self, module: &ErasedModule)
Process a module: mark all consts reachable from roots as reachable.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for ErasedReachability
impl RefUnwindSafe for ErasedReachability
impl Send for ErasedReachability
impl Sync for ErasedReachability
impl Unpin for ErasedReachability
impl UnsafeUnpin for ErasedReachability
impl UnwindSafe for ErasedReachability
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more