lib/language/parser.rb in language-ruby-0.7.0 vs lib/language/parser.rb in language-ruby-0.8.0

- old
+ new

@@ -17,10 +17,10 @@ unless @cursor == @input.size || !check_end_of_input raise NotEndOfInput, self end - @output.present? ? @output : Output.new(@buffer) + @output.present? ? @output : Output.new(@buffer.empty? ? nil : @buffer) end def consume(n) raise EndOfInput, self unless @cursor + n <= @input.size