Struct conch_parser::parse::SourcePos [] [src]

pub struct SourcePos {
    pub byte: usize,
    pub line: usize,
    pub col: usize,
}

Indicates a character/token position in the original source.

Fields

The byte offset since the start of parsing.

The line offset since the start of parsing, useful for error messages.

The column offset since the start of parsing, useful for error messages.

Methods

impl SourcePos
[src]

Constructs a new, starting, source position

Increments self using the length of the provided token.

Trait Implementations

impl Debug for SourcePos
[src]

Formats the value using the given formatter.

impl PartialEq for SourcePos
[src]

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

impl Eq for SourcePos
[src]

impl Copy for SourcePos
[src]

impl Clone for SourcePos
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl Default for SourcePos
[src]

Returns the "default value" for a type. Read more

impl Display for SourcePos
[src]

Formats the value using the given formatter. Read more