class Grammars::Rule

Attributes

matcher[R]
token[R]

Public Class Methods

new(matcher, token) click to toggle source
# File lib/grammars/rule.rb, line 3
def initialize(matcher, token)
  @matcher, @token = matcher, "<#{token.to_s.upcase}>"
  unless @matcher.instance_of? Regexp
    @matcher = @matcher.matcher
  end
end