hcl_edit

Trait Span

Source
pub trait Span {
    // Required method
    fn span(&self) -> Option<Range<usize>>;
}
Expand description

A trait for objects which carry span information.

Required Methods§

Source

fn span(&self) -> Option<Range<usize>>

Obtains the span information. This only returns Some if the value was emitted by the parser.

The returned range represents a zero-based start and end byte offset in the input from which this object was parsed.

Implementations on Foreign Types§

Source§

impl<T> Span for Box<T>
where T: Span,

Implementors§