class Racc::ParserFileGenerator
Constants
- RE_CACHE
- RUBY_PATH
Public Class Methods
# File lib/racc/parserfilegenerator.rb, line 72 def initialize(states, params) @states = states @grammar = states.grammar @params = params end
Public Instance Methods
# File lib/racc/parserfilegenerator.rb, line 78 def generate_parser string_io = StringIO.new init_line_conversion_system @f = string_io parser_file string_io.rewind string_io.read end
# File lib/racc/parserfilegenerator.rb, line 89 def generate_parser_file(destpath) init_line_conversion_system File.open(destpath, 'w') {|f| @f = f parser_file } File.chmod 0755, destpath if @params.make_executable? end
State
Transition Table Serialization
# File lib/racc/parserfilegenerator.rb, line 254 def put_state_transition_table(f) @f = f state_transition_table end