Type Alias Span

Source
pub type Span = Range<usize>;
Expand description

Byte span of ast fragment

Aliased Type§

struct Span {
    pub start: usize,
    pub end: usize,
}

Fields§

§start: usize

The lower bound of the range (inclusive).

§end: usize

The upper bound of the range (exclusive).

Trait Implementations§

Source§

impl Spanned for Span

Source§

fn span(&self) -> Span

Compute byte span of an ast fragment
Source§

fn join_span(&self, other: &impl OptSpanned) -> Span

Compute the minimal span containing both self and other