get address of object if opCast is overridden
    Jonathan M Davis 
    jmdavisProg at gmx.com
       
    Sat Dec  1 09:23:59 PST 2012
    
    
  
On Saturday, December 01, 2012 12:05:49 Artur Skawina wrote:
> > So, unless there's a way to do it without a cast, you're stuck. And I have
> > no idea how you could possibly do it without a cast.
> 
>    *cast(void**)&O // assuming O is a class
Are you sure? I'd be _very_ wary of that, because references aren't the same 
as pointers. I don't believe that there's any guarantee whatsoever that that 
will work, even if it happens to work now (which it may or may not).
- Jonathan M Davis
    
    
More information about the Digitalmars-d-learn
mailing list