Pointers-to-members
Coleen Phillimore
coleen at zko.dec.com
Thu Mar 30 21:58:16 UTC 2000
For pointers to virtual functions, the ABI used to say multiply
by two and add one. I thought the purpose of this was to be able
to distinguish between non-virtual and virtual functions.
It appears that the multiplication by two was removed. Why?
If a virtual function occupies slot 3 in the vtable, you can't OR
with '1' to determine whether the function is virtual anymore.
Also, if you have a virtual function in slot 7 in the vtable, then add
one, it'll look like a quadword aligned address from the lower bytes.
Was there a new way to distinguish between non-virtual and virtual
functions in pointer to member functions, that I missed?
thanks,
Coleen
--
-----------------------------------------------------------------------
Coleen Phillimore | mailto:coleen at zko.dec.com
Compaq Computer Corp. Nashua, NH | COMPAQ C++ Compiler Development
-----------------------------------------------------------------------
More information about the cxx-abi-dev
mailing list