"is" operator for structures?
    Steven Schveighoffer 
    schveiguy at yahoo.com
       
    Wed May  9 09:48:14 PDT 2012
    
    
  
On Wed, 09 May 2012 12:21:05 -0400, Gor Gyolchanyan  
<gor.f.gyolchanyan at gmail.com> wrote:
> If "is" was overloadable, one could make a legitimate reference types
> via structs. The opAssign would change the reference, opEquals would
> call the opEquals of the referred object, opBinary(string op : `is`)
> would compare the references... Just like classes.
Yes, this is probably the only legitimate use case.  I'm not sure how to  
make it work, exactly.  But the functionality of 'is' should not be  
affected, it's too valuable the way it is to change it.
-Steve
    
    
More information about the Digitalmars-d
mailing list