lib/tracksperanto/buffering_reader.rb in tracksperanto-2.8.6 vs lib/tracksperanto/buffering_reader.rb in tracksperanto-2.9.0

- old
+ new

@@ -1,5 +1,6 @@ +# -*- encoding : utf-8 -*- # Shake uses this reader to parse byte by byte without having to read byte by byte. # Reading byte by byte is very inefficient, but we want to parse byte by byte since # this makes parser construction much easier. So what we do is cache some chunk of the # passed buffer and read from that. Once exhausted there will be some caching again, # and ad infinitum until the passed buffer is exhausted @@ -34,6 +35,6 @@ def cache data = @io.read(@bufsize) @buf = StringIO.new(data.to_s) # Make nil become "" end -end \ No newline at end of file +end