class Racc::Goto

Represents a transition on the grammar. “Real goto” means a transition by nonterminal, but this class treats also terminal’s. If one is a terminal transition, .ident returns nil.

Attributes

from_state[R]
ident[R]
symbol[R]
to_state[R]

Public Class Methods

new(ident, sym, from, to) click to toggle source
# File racc-1.8.1/lib/racc/state.rb, line 772
def initialize(ident, sym, from, to)
  @ident      = ident
  @symbol     = sym
  @from_state = from
  @to_state   = to
end

Public Instance Methods

inspect() click to toggle source
# File racc-1.8.1/lib/racc/state.rb, line 784
def inspect
  "(#{@from_state.ident}-#{@symbol}->#{@to_state.ident})"
end