[C++-sig] Re: sub module support in V2
David Abrahams
david.abrahams at rcn.com
Mon Jun 10 02:29:23 CEST 2002
From: "Dave Hawkes" <daveh at cadlink.com>
>
> "David Abrahams" <david.abrahams at rcn.com> wrote in message
> news:285601c21000$20b51d20$6601a8c0 at boostconsulting.com...
> >
> > Those sound like good choices. It might be difficult to get nested
classes
> > to work, but maybe that scoping is best done using the class name:
> >
> > class<ctest::nested>("ctest.nested")
> > ...
> > ;
> >
>
> That's straight forward apart from one small detail. Unlike modules, if a
> parent does not exist I'm not sure that I can safely create it on the
fly.
> If I create an empty dummy class it may not have the correct base classes
> when it is eventually constructed and so I would have to tear out the
dummy
> and replace it with the correct one when that happens. I'm not sure that
I
> like any of this, so maybe there should just be an assertion if the
parent
> classes are not created prior to the nested classes?
I thought of that; I think it's about all we can do...
...unless we add a parent scope argument to class' constructor, reminiscent
of v1. At least it could be optional in v2.
-Dave
More information about the Cplusplus-sig
mailing list