lib/abstractivator/enumerable_ext.rb in abstractivator-0.17.0 vs lib/abstractivator/enumerable_ext.rb in abstractivator-0.18.0
- old
+ new
@@ -146,6 +146,10 @@
xs.concat(get_children_proc.call(x))
end
end
acc
end
+
+ def fold_right(*args, &combine)
+ reverse.reduce(*args, &combine&.reverse_args)
+ end
end