pub struct Instances<'g> { /* private fields */ }Expand description
One file’s body beside what its parameters stand for: the body is shared, the scope is not.
Implementations§
Source§impl<'g> Instances<'g>
impl<'g> Instances<'g>
pub fn origin(&self, instance: &str) -> Option<&str>
pub fn paths(&self) -> impl Iterator<Item = &str>
pub fn holds(&self, path: &str) -> bool
Sourcepub fn instance_of(&self, target: &str) -> Result<String, EngineError>
pub fn instance_of(&self, target: &str) -> Result<String, EngineError>
A bare file name is the file read as a root, on its own terms; a call site’s instance carries the bindings that made it.
pub fn instances_of<'a>( &'a self, file: &'a str, ) -> impl Iterator<Item = String> + 'a
pub fn at<'a>(&'a self, path: &str) -> Option<(&'a Expr, Cx<'a>)>
pub fn bindings<'a>( &'a self, path: &str, ) -> Option<Vec<(&'a str, &'a Expr, Cx<'a>)>>
Source§impl<'g> Instances<'g>
impl<'g> Instances<'g>
Sourcepub fn follow<'a, R>(
&'a self,
e: &'a Expr,
cx: Cx<'a>,
go: impl FnOnce(&'a Expr, Cx<'_>) -> R,
) -> Option<R>
pub fn follow<'a, R>( &'a self, e: &'a Expr, cx: Cx<'a>, go: impl FnOnce(&'a Expr, Cx<'_>) -> R, ) -> Option<R>
A bound name continues in what it stands for; anything else is read where it stands.
pub fn node<'a>(&'a self, e: &'a Expr, cx: Cx<'_>) -> Node<'a>
pub fn reads_self(&self, path: &str) -> bool
Trait Implementations§
Auto Trait Implementations§
impl<'g> Freeze for Instances<'g>
impl<'g> RefUnwindSafe for Instances<'g>
impl<'g> Send for Instances<'g>
impl<'g> Sync for Instances<'g>
impl<'g> Unpin for Instances<'g>
impl<'g> UnsafeUnpin for Instances<'g>
impl<'g> UnwindSafe for Instances<'g>
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