From: Robert Dober Date: 2008-06-12T03:30:34+09:00 Subject: Re: each with else On Wed, Jun 11, 2008 at 8:23 PM, Martin DeMello wrote: > On Wed, Jun 11, 2008 at 11:18 AM, Robert Dober wrote: >> >> Martin I think you did not read my reply reagrding this technique, it >> is funny though that you want to define Object#is_empty, I would say >> that the Ruby way would be Object#empty? > > I did - mine is different in that it doesn't require explicit use of > the built-in control structures like if/else or and Indeed you did!! I only now grasp your concept, very nice indeed :). Sorry should have known you better, we can of course emulate things like if_true, if_nil, unless_fourtytwo (well that one is a joke ). But I guess we are getting too Smalltalkish here, Ruby shall remain Ruby, but we can play with it as much as we want. Cheers Robert -- http://ruby-smalltalk.blogspot.com/ --- As simple as possible, but not simpler. Albert Einstein