On (26 Jul 97) Darin Mcbride wrote to Jerry Coffin...
CS> I want to define two classes like the following:
CS> class A
CS> {
CS> A(int a) { };
CS> B func1() { return B(1); };
CS> }
CS> class B
CS> {
CS> B(int a) { };
CS> A func2() { return A(1); };
CS> }
DM> I'd say you can't do it.
Oops - you're right. I glanced at the syntactical problem but didn't
really think about the whole problem. To accomplish this general sort
of thing, you'd have to return a pointer to the incomplete type rather
than an instance of the incomplete type.
Later,
Jerry.
... The Universe is a figment of its own imagination.
--- PPoint 1.90
---------------
* Origin: Point Pointedly Pointless (1:128/166.5)
|