diff options
Diffstat (limited to 'grammar.rb')
-rw-r--r-- | grammar.rb | 8 |
1 files changed, 2 insertions, 6 deletions
@@ -1,5 +1,6 @@ require 'nlp_ruby' + class Terminal attr_accessor :w @@ -44,7 +45,7 @@ class Rule end def to_s - "#{lhs} -> #{rhs.map{|i|i.to_s}.join ' '} (#{arity}) (#{@span.left}, #{@span.right})" + "#{lhs} -> #{rhs.map{|i|i.to_s}.join ' '} a:#{arity} (#{@span.left}, #{@span.right})" end def arity @@ -89,8 +90,3 @@ class Grammar end end - - - - - |