Sha256: b695cb412d2d6193386bde095d08cdf2b9b3144d1dc8365c34ec163251417866
Contents?: true
Size: 814 Bytes
Versions: 17
Compression:
Stored size: 814 Bytes
Contents
module Rley # This module is used as a namespace module Syntax # This module is used as a namespace # Abstract class for grammar symbols. # A grammar symbol is an element that appears in grammar rules. class GrmSymbol # The name of the grammar symbol attr_reader(:name) # Constructor. # aName [String] The name of the grammar symbol. def initialize(aName) @name = aName.dup end # Return true iff the symbol is a terminal def terminal?() # Default implementation to override if necessary return false end # The String representation of the grammar symbol # @return [String] def to_s() return name.to_s end end # class end # module end # module # End of file
Version data entries
17 entries across 17 versions & 1 rubygems