Gianni Mariani <gi3nospam@mariani.wswrote
Quote:
Ole Nielsby wrote:...
Yes, I am not sure why the C++ gods thought that it was a good
idea to hide inherited functions with the same name. But it is so.
|
We mortals must humbly bow to the gods and accept that we do
not always understand their ways. However I promise I won't
do this thing to you, should my own PILS programming system
(which has forced me to learn C++ because I need to implement
it on common ground between Redmond and Tuxistan) succeed
in making me immortal. I have other tricks in my bag to stun you,
but not this one.
Quote:
However, the "using" keyword can "unhide" it for you.
>
(Note that MSVC 2003 breaks on this.).
|
Luckily, it works in MSVC 2005 which is what I am using
for the time being - and it works with virtuals, too, though
I am not at easy with the notation:
using Baseclass::method;
since Baseclass::method(...) usually disables the virtual
lookup, it isn't obvious that the using...::... respects virtuals.
Anyway, thanks for helping me out. I'm glad to know I'm
not the first to be puzzled by this feature.