Я читаю текст C ++ по адресу https://cs.senecac.on.ca/~chris.szalwinski/archives/btp200.082/content/dclas.html.. В начале автор написал: "A derived class with depth is a derived class that accesses resources through one or more of the derived class' instance variables."
A derived class with depth is a derived class that accesses resources through one or more of the derived class' instance variables.
Я действительно не понимаю этого определения, хотя могу понять остальноетекста.Кто-нибудь может дать мне четкое объяснение или пример?
I предположим, это относится к цепочке производных классов:
struct Base { int i; }; struct D0: Base {}; struct D1: D0 {}; int main() { D1 d; d.i; // access i through D0 through Base }