Crate lib_ruby_parser[][src]

A Ruby parser written in Rust.

Uses bison under the hood.

Modules

lex_states

Mod with all known lex states

nodes

Module with all known node types

source

Module with everything related to output of the Parser, but not related to AST, like Comment, Input, CustomDecoder

token_rewriter

Module to perform token rewriting

traverse

Module to perform recursive traversing

Structs

Bytes

Representation of a byte sequence

Diagnostic

Diagnostic message that comes from the parser when there's an error or warning

LexState

State of the lexer

Lexer

A struct responsible for converting a given input into a sequence of tokens

Loc
Parser

A Bison parser, automatically generated from src/parser.features.y.

ParserOptions

Configuration of the parser

ParserResult

Combination of all data that Parser can give you

ReservedWord

Representation of a reserved word in Ruby

StaticEnvironment

Stack of local variables in nested scopes

StringValue

Representation of the value of the string literal

Token

A token that is emitted by a lexer and consumed by a parser

Enums

DiagnosticMessage

Enum of all possible diagnostic message (both warnings and errors)

ErrorLevel

Error level of the diagnostic message

Node

Generic combination of all known nodes.

Functions

reserved_word

Returns a ReservedWord for a given string slice.

token_name

Maps token ID into human-readable name