From: bbiker Date: 2007-12-12T15:27:03+09:00 Subject: Re: opposite .nil? On Dec 11, 3:03 pm, Andrew Stone wrote: > Note: parts of this message were removed by the gateway to make it a legal Usenet post. > > > 1) No such opposite-of-nil? method exists. If you want it, add it. > > Thanks for actually answering my question. Much appreciated. > > 2) In the particular example above (which I realize is just an> example) you could write that as: > > > def should_this_by_done? > > am_I_sure? unless !my_object || my_object.var.nil? > > end > > > But, of course, that just moves the negation. > > Sure, I was just looking for a more readable construct. Thanks again for > your reply. > > -- > Andrew Stone what about def should_this_be_done? am_1_sure? && my_object.var && my_object.var end KISS