class Cabbage::Item(T)
- Cabbage::Item(T)
- Reference
- Object
Overview
Fixme: Change to struct when derivations are known to work. Requires pointer magic to avoid recursive structs.
Included Modules
Defined in:
cabbage/item.crConstructors
Instance Method Summary
- #complete
- #lhs
- #lr0!
- #nonterminal_action(item)
- #predict(current)
- #rule!
- #start : Set(T)
- #start=(start : Set(T))
- #stop : Set(T)
- #stop=(stop : Set(T))
- #tag : LR0(T) | GrammarSymbol
- #tag=(tag : LR0(T) | GrammarSymbol)
- #terminal_action(char)
-
#to_s
Returns a nicely readable and concise string representation of this object, typically intended for users.
Instance methods inherited from module Cabbage::Derivation(T)
add_another_derivation(previous, child)
add_another_derivation,
add_derivation(previous, child)
add_derivation,
add_second_derivation(previous, child)
add_second_derivation,
child : Item(T) | DerivationNode(T) | Nil
child,
child=(child : Item(T) | DerivationNode(T) | Nil)
child=,
derivation_list?
derivation_list?,
evaluate(prev, &)
evaluate,
next_derivation : Item(T) | DerivationNode(T) | Nil
next_derivation,
next_derivation=(next_derivation : Item(T) | DerivationNode(T) | Nil)
next_derivation=,
previous : Item(T) | DerivationNode(T) | Nil
previous,
previous=(previous : Item(T) | DerivationNode(T) | Nil)
previous=,
rhs
rhs,
same?(previous, child)
same?,
walk
walk
Constructor Detail
def self.new(tag : Cabbage::LR0(T) | Char | Symbol, start : Cabbage::Set(T), stop : Cabbage::Set(T))
#
Instance Method Detail
def to_s
#
Description copied from class Object
Returns a nicely readable and concise string representation of this object, typically intended for users.
This method should usually not be overridden. It delegates to
#to_s(IO)
which can be overridden for custom implementations.
Also see #inspect
.