rune::compile

Trait Located

Source
pub trait Located {
    // Required methods
    fn location(&self) -> Location;
    fn as_spanned(&self) -> &dyn Spanned;
}
Expand description

Trait for things that have a Location.

Required Methods§

Source

fn location(&self) -> Location

Get the assocaited location.

Source

fn as_spanned(&self) -> &dyn Spanned

Get located item as spanned.

Trait Implementations§

Source§

impl Spanned for dyn Located

Source§

fn span(&self) -> Span

Get the span of the type.

Implementors§