Class: Racc::Prec

Inherits:
Object show all
Defined in:
lib/racc/grammar.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(symbol, lineno) ⇒ Prec

Returns a new instance of Prec.



868
869
870
871
# File 'lib/racc/grammar.rb', line 868

def initialize(symbol, lineno)
  @symbol = symbol
  @lineno = lineno
end

Instance Attribute Details

#linenoObject (readonly)

Returns the value of attribute lineno.



880
881
882
# File 'lib/racc/grammar.rb', line 880

def lineno
  @lineno
end

#symbolObject (readonly)

Returns the value of attribute symbol.



879
880
881
# File 'lib/racc/grammar.rb', line 879

def symbol
  @symbol
end

Instance Method Details

#nameObject Also known as: inspect



873
874
875
# File 'lib/racc/grammar.rb', line 873

def name
  "=#{@symbol}"
end