: D B, D B.
In C ++: if class D inherits privately from class B, then D is not B, since no one knows. Straustrup thinks of this as an alternative to composition. I consider this one of the mistakes in C ++ design precisely for the reason that, in my opinion, “inherit” should be synonymous with “is a”.
source
share