lib/junoser/squash.rb in junoser-0.3.3 vs lib/junoser/squash.rb in junoser-0.3.4

- old
+ new

@@ -40,10 +40,18 @@ end rule(oneline: sequence(:strs)) do strs.join(' ') end + + rule(enum: simple(:str)) do + str + end + + rule(enum: sequence(:strs)) do + strs.join(' ') + end end class Squash def initialize(io_or_string) @input = io_or_string @@ -85,6 +93,6 @@ @lines.each do |l| l.sub!(/#{pattern}/) { $1 } end end end -end \ No newline at end of file +end