class Ven::Parselet::PNudMacro
Overview
Represents a nud macro and expands it on a parse.
When triggered, it interprets the nud parameters it was
initialized with and passes the results to the expansion
visitor (ReadExpansion
).
It is one of the semantic nuds.
Defined in:
ven/parselet/nud.crConstructors
Instance Method Summary
-
#args!
Reads the arguments of this nud macro by interpreting the parameters it accepts.
- #parse(tag, token)
-
#tail!
Reads the tail slurpie.
Instance methods inherited from class Ven::Parselet::Nud
parse(tag : QTag, token : Word)
parse,
parse!(parser : Reader, tag : QTag, token : Word)
parse!
Instance methods inherited from class Ven::Parselet::Share
block(opening = true, semicolon : Bool = false)
block,
die(message : String)
die,
led(precedence = @precedence)
led,
precedence : Precedence
precedence,
semicolon : Bool
semicolon,
symbol(tag, token = nil) : QSymbol
symbol
Constructor methods inherited from class Ven::Parselet::Share
new(precedence : Ven::Precedence = Precedence::ZERO)
new
Constructor Detail
Instance Method Detail
def args!
#
Reads the arguments of this nud macro by interpreting the parameters it accepts.
Returns a hash of parameter names mapped to the corresponding
arguments. Tail slurpie (*
) is stored under $-tail
.