C++ (Qt)#include <iostream>using namespace std; struct A{ void print() const {cout << "A\n";}}; struct B: public A{ void print() const {cout << "B\n";}}; struct C: public B{ void print() const {cout << "C\n";}}; template<class T>void print(const T &someClass){ someClass.print();} int main() { print(A()); print(B()); print(C()); return 0;}
C++ (Qt)class GuiItemA: public GuiObjectA, public ExtItem1<GuiObjectA>
C++ (Qt)template <class GuiItem>class ExtendedGuiItemA: public GuiItem