lib/bmg/operator/allbut.rb in bmg-0.18.2 vs lib/bmg/operator/allbut.rb in bmg-0.18.3
- old
+ new
@@ -28,9 +28,10 @@
attr_reader :butlist
public
def each
+ return to_enum unless block_given?
seen = {}
@operand.each do |tuple|
allbuted = tuple_allbut(tuple)
unless seen.has_key?(allbuted)
yield(allbuted)