The philosophy of Nothing
    Neal Gafter 
    neal at gafter.com
       
    Sun Nov 29 13:49:40 PST 2009
    
    
  
On Sun, Nov 29, 2009 at 12:58 PM, Paul Benedict <pbenedict at apache.org>wrote:
> Yes, I understand that the the empty set is a subset of any other set.
> I looked it up just to refresh myself:
> http://en.wikipedia.org/wiki/Empty_set
>
> But what does an "empty set" (not java.uitl.Set) mean to Java? I
> perceive "Nothing" as pure .. well, nothingness. I liken such a type
> to be like NULL in SQL which has no equality -- even to itself.
>
Not the same as NULL.  NULL is a value.  You can put it in a variable.
Nothing, on the other hand, you can't ever get one of.  If you try to
construct a program that computes an expression of type Nothing then every
way yu try to do it you'll find that the program necessarily can't get to
the point where the value of type Nothing is present.  Such a program must
necessarily (by the structure of the type system) transfer control elsewhere
before getting to that point, for example by throwing an exception, or
"return"ing.
Cheers,
Neal
    
    
More information about the coin-dev
mailing list