General

Profile

Killa (Łukasz Strzebińczyk)

Issues

open closed Total
Assigned issues 0 0 0
Reported issues 0 1 1

Activity

08/27/2014

11:11 PM Ruby Feature #9867: Introduce each/else block into ruby
Sorry for the delay.
I don't think I am able in specifying it in needed level of detail: (. If that's up to me, the issue can be closed.
Killa (Łukasz Strzebińczyk)

05/28/2014

09:57 AM Ruby Feature #9867: Introduce each/else block into ruby
I came up with this idea after some study on http://handlebarsjs.com/. In that case, the 'else' block is invoked when collection is empty.
This would have clear translation for Array or Hash, however I'm having a problem trying to defin...
Killa (Łukasz Strzebińczyk)

05/27/2014

12:42 PM Ruby Feature #9867 (Closed): Introduce each/else block into ruby
Hi
Code like this happens quite often:
if array.any?
array.each do |elem|
some_work
end
else
do_something_else
end
I was thinking if it was possible, to introduce syntax like this:
...
Killa (Łukasz Strzebińczyk)

Also available in: Atom