Topic: Covariant returns and forward declaration of derived classes
Author: warsaw@nlm.nih.gov (Barry A. Warsaw)
Date: 03 Nov 1993 17:40:39 GMT Raw View
Has any thought been given by the standards bodies to allow forward
declarations of derived types? In light of covariant returns for
virtual methods, this would seem to be a very useful feature.
-Barry
-------------------- snip snip --------------------
class B; // forward decl
class X {
public:
virtual B* figureItOut();
};
class D : public B; // derived forward decl, would be nice if legal
class Y : public X {
public:
virtual D* figureItOut();
};