Sha256: 6ce24deabf258fe5fe95a11255ac719c33962cdbeef3c94f71fea890b3528966
Contents?: true
Size: 726 Bytes
Versions: 6
Compression:
Stored size: 726 Bytes
Contents
module Lrama class Grammar class Code class InitialActionCode < Code private # * ($$) yylval # * (@$) yylloc # * ($1) error # * (@1) error def reference_to_c(ref) case when ref.type == :dollar && ref.name == "$" # $$ "yylval" when ref.type == :at && ref.name == "$" # @$ "yylloc" when ref.type == :dollar # $n raise "$#{ref.value} can not be used in initial_action." when ref.type == :at # @n raise "@#{ref.value} can not be used in initial_action." else raise "Unexpected. #{self}, #{ref}" end end end end end end
Version data entries
6 entries across 6 versions & 1 rubygems