pub struct Analysis {
pub symbols: Vec<Symbol>,
pub references: Vec<Reference>,
}Expand description
The result of analysis.
Fields§
§symbols: Vec<Symbol>Declared names (in module order, then declaration order).
references: Vec<Reference>Positions where names are used. Only those that could be resolved.
Implementations§
Source§impl Analysis
impl Analysis
Sourcepub fn symbol_at(&self, module: &str, line: u32, col: u32) -> Option<usize>
pub fn symbol_at(&self, module: &str, line: u32, col: u32) -> Option<usize>
The symbol that the name at the position (a declaration itself, or a use) refers to.
Sourcepub fn references_to(&self, symbol: usize) -> impl Iterator<Item = &Reference>
pub fn references_to(&self, symbol: usize) -> impl Iterator<Item = &Reference>
References to the symbol (declarations are not included).
Trait Implementations§
impl Eq for Analysis
impl StructuralPartialEq for Analysis
Auto Trait Implementations§
impl Forget for Analysis
impl Freeze for Analysis
impl Move for Analysis
impl RefUnwindSafe for Analysis
impl Send for Analysis
impl Sync for Analysis
impl Unpin for Analysis
impl UnsafeUnpin for Analysis
impl UnwindSafe for Analysis
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