Re:C++ is a hack
by slavik81 on Tuesday February 16, 2016 @08:48PM
(#11114586)
Just to be clear, that's not in conflict with what the author claimed. You can't call that method using a pointer to the derived class. That would be an access violation, because it was declared private. You need to use a pointer of the superclass type.
To be honest, I find this behaviour useful so it doesn't upset me. It's a decent way to mark off functions that you needed to implement to satisfy an internal interface as not-for-users.
[ Parent
| on HN ]
Question: Is struct inheritance public by default?