Private enum members + Descent
Rainer Deyke
rainerd at eldwood.com
Sat Oct 24 18:41:14 PDT 2009
Denis Koroskin wrote:
> On Sun, 25 Oct 2009 02:22:51 +0300, Michel Fortin
> <michel.fortin at michelf.com> wrote:
>> Sounds like you want enum inheritance: one enum being a superset of
>> another. :-)
I was about to post the same thing.
> It was previously proposed, but it was rejected because it works
> "backwards": downcasting is allowed while upcasting is prohibited.
Just like contravariant functions. Only less so.
--
Rainer Deyke - rainerd at eldwood.com
More information about the Digitalmars-d
mailing list