Search results

There are no results.

syntax.Lexer

trait pub Lexer

A type that turns a buffer into a token stream.

Required methods

buffer

Show source code
Hide source code
fn pub mut buffer -> mut Buffer
fn pub mut buffer -> mut Buffer

The buffer to turn into a token stream.

next

Show source code
Hide source code
fn pub mut next -> Option[Token]
fn pub mut next -> Option[Token]

Returns the next token in the token stream.

Default methods

to_array

Show source code
Hide source code
fn pub move to_array -> Array[Token] {
  let tokens = []

  loop {
    let Some(t) = self.next else break

    tokens.push(t)
  }

  tokens
}
fn pub move to_array -> Array[Token]

Returns an Array containing all the tokens in the token stream.

Implementations

syntax.lexer.c.

Lexer

impl Lexer for Lexer
syntax.lexer.fish.

Lexer

impl Lexer for Lexer
syntax.lexer.inko.

Lexer

impl Lexer for Lexer
syntax.lexer.json.

Lexer

impl Lexer for Lexer
syntax.lexer.make.

Lexer

impl Lexer for Lexer
syntax.lexer.ruby.

Lexer

impl Lexer for Lexer
syntax.lexer.rust.

Lexer

impl Lexer for Lexer
syntax.lexer.shell.

Lexer

impl Lexer for Lexer
syntax.lexer.toml.

Lexer

impl Lexer for Lexer