Module: RubyLexer::State::Values

Constant Summary collapse

EXPR_NONE =
State.new    0x0, expr_names
EXPR_BEG =
State.new    0x1, expr_names
EXPR_END =
State.new    0x2, expr_names
EXPR_ENDARG =
State.new    0x4, expr_names
EXPR_ENDFN =
State.new    0x8, expr_names
EXPR_ARG =
State.new   0x10, expr_names
EXPR_CMDARG =
State.new   0x20, expr_names
EXPR_MID =
State.new   0x40, expr_names
EXPR_FNAME =
State.new   0x80, expr_names
EXPR_DOT =
State.new  0x100, expr_names
EXPR_CLASS =
State.new  0x200, expr_names
EXPR_LABEL =
State.new  0x400, expr_names
EXPR_LABELED =
State.new  0x800, expr_names
EXPR_FITEM =
State.new 0x1000, expr_names
EXPR_BEG_ANY =
EXPR_BEG | EXPR_MID    | EXPR_CLASS
EXPR_ARG_ANY =
EXPR_ARG | EXPR_CMDARG
EXPR_END_ANY =
EXPR_END | EXPR_ENDARG | EXPR_ENDFN
EXPR_LAB =

extra fake lex_state names to make things a bit cleaner

EXPR_ARG|EXPR_LABELED
EXPR_LIT =
EXPR_END|EXPR_ENDARG
EXPR_PAR =
EXPR_BEG|EXPR_LABEL
EXPR_PAD =
EXPR_BEG|EXPR_LABELED
EXPR_NUM =
EXPR_LIT
STR_FUNC_BORING =
State.new 0x00,    str_func_names
STR_FUNC_ESCAPE =
State.new 0x01,    str_func_names
STR_FUNC_EXPAND =
State.new 0x02,    str_func_names
STR_FUNC_REGEXP =
State.new 0x04,    str_func_names
STR_FUNC_QWORDS =
State.new 0x08,    str_func_names
STR_FUNC_SYMBOL =
State.new 0x10,    str_func_names
STR_FUNC_INDENT =

<<-HEREDOC

State.new 0x20,    str_func_names
STR_FUNC_LABEL =
State.new 0x40,    str_func_names
STR_FUNC_LIST =
State.new 0x4000,  str_func_names
STR_FUNC_TERM =
State.new 0x8000,  str_func_names
STR_FUNC_DEDENT =

<<~HEREDOC

State.new 0x10000, str_func_names
STR_SQUOTE =

TODO: check parser25.y on how they do STR_FUNC_INDENT

STR_FUNC_BORING
STR_DQUOTE =
STR_FUNC_EXPAND
STR_XQUOTE =
STR_FUNC_EXPAND
STR_REGEXP =
STR_FUNC_REGEXP | STR_FUNC_ESCAPE | STR_FUNC_EXPAND
STR_SWORD =
STR_FUNC_QWORDS | STR_FUNC_LIST
STR_DWORD =
STR_FUNC_QWORDS | STR_FUNC_EXPAND | STR_FUNC_LIST
STR_SSYM =
STR_FUNC_SYMBOL
STR_DSYM =
STR_FUNC_SYMBOL | STR_FUNC_EXPAND
STR_LABEL =
STR_FUNC_LABEL