From: Michael Morin Date: 2008-09-01T00:03:14+09:00 Subject: Re: Simple conditional causing hanging? Ryan Davis wrote: > > On Aug 30, 2008, at 18:56 , Michael Morin wrote: > >> You want @thisLine.nil?. Alternatively, you could use @thisLine == >> nil, @thisLine.class == NilClass, or even @thisClass === NilClass. >> But @thisLine.nil? is the preferred way. > > NilClass === @thisLine > > class must come first to use Module#=== > > Ah, I'd actually wondered about that. -- Michael Morin Guide to Ruby http://ruby.about.com/ Become an About.com Guide: beaguide.about.com About.com is part of the New York Times Company