From: Vidar Hokstad Date: 2006-10-29T04:05:10+09:00 Subject: Re: nil.to_s != "nil" Eero Saynatkari wrote: > On 2006.10.28 00:20, Phrogz wrote: > > You are correct that "" != nil, but "nil" != nil also. > > What are you really trying to achieve? And, did you know that > > nil.inspect yields "nil"? > > Yes. I want consistency. It is consistent. "to_s" returns a string representation of the value(s) of the object you call it on. The value of the object nil is _nothing_ and the empty string is a sensible representation of that. Vidar