From: "David A. Black" Date: 2005-03-14T09:53:07+09:00 Subject: Re: Array#nitems and Object#nil? Hi -- On Mon, 14 Mar 2005, Eliah Hecht wrote: > On Sun, 13 Mar 2005 21:37:24 +0900, Yukihiro Matsumoto > wrote: >> Nil is a nil is a nil. Defining nil? to be true doesn't make >> something nil. It's just a false predicate. > > In that case, what's the point of nil?? I'm not sure what you mean by > "It's just a false predicate"; an object that returns true for nil? > doesn't seem to be false-valued. Does nil? do anything in the > language, or is it just meant to be a convient way to check if > something == nil? nil is an object, so any other object that says "I am the object nil" (which is what nil? tests for) is giving false information. You can rig an object to do that, just as you can rig, say, the number 3 to tell you that it's equal to the number 4, but it's still basically untrue. David -- David A. Black dblack@wobblini.net