Skip to main content

to_parser_span_range

Function to_parser_span_range 

Source
pub fn to_parser_span_range(
    start: GrammarSpan<'_>,
    end: GrammarSpan<'_>,
) -> Span
Expand description

Convert grammar span range (start, end) to parser span Convert a grammar span range where end is the remainder span (i.e. the nom rest after a match). This sets the end position to the end.location_offset() (start of the remainder), matching inline parser usage patterns like to_parser_span_range(start, rest).