def generate_terminals(grammar)
      terminals = [:$EOF]

      grammar.terminals.each do |term|
        terminals << term.name.to_sym
      end

      return terminals
    end
def generate_terminals(grammar)
      terminals = [:$EOF]

      grammar.terminals.each do |term|
        terminals << term.name.to_sym
      end

      return terminals
    end
Returns an Array containing all the terminal names as symbols. The first
 terminal is always `:$EOF` to ensure the array has the same amount of rows
 as there are columns in the `table` array.

 @param [LL::CompiledGrammar] grammar
 @return [Array]