This kind of diamond shaped derivation is almost never a good idea, even if it is supported by C++ in general.
It gets you into all kinds of ambiguous situations, e.g. if your class A has a virtual method and both P and Q implement it, which one of the two implementations is called when you call the method on Z?
In the case of QObject subclasses this kind of hierachy is made unavailable to make the QObject addons work properly, e.g. the code generated by MOC when it encounters classes with the Q_OBJECT marker, etc.
What is you actual use case?
Cheers,
_
Bookmarks