cplusplus
.com
TUTORIALS
REFERENCE
ARTICLES
FORUM
C++
Tutorials
Reference
Articles
Forum
Forum
Beginners
Windows Programming
UNIX/Linux Programming
General C++ Programming
Lounge
Jobs
Forum
General C++ Programming
why pure private virtual member?
why pure private virtual member?
Jul 16, 2016 at 10:27pm UTC
JUAN DENT
(326)
Hi,
If I declare a pure virtual member function in the private section of a class A, then how can I override it in a subclass B of A since it is inaccessible?
Regards,
Juan
Jul 16, 2016 at 10:39pm UTC
LB
(13399)
Private virtual functions can be overridden. The class that overrides them, however, can only call its own version or use virtual dispatch.
Jul 16, 2016 at 10:41pm UTC
gedamial
(313)
http://stackoverflow.com/questions/3970279/what-is-the-point-of-a-private-pure-virtual-function
Topic archived. No new replies allowed.