R
red floyd
Does anyone know if C++0x will address the issue of enumerated subtypes?
That is, if I have an enum, and want a type-compatible subtype of it....
Something along the lines of
enum Day {
Sunday,
Monday,
Tuesday,
Wednesday,
Thursday,
Friday,
Saturday
};
and I want to create a subtype that's just the weekdays (Monday through
Friday). However, I don't want to have to do casting between the two.
This is equivalent to the Ada subtype construct.
Will C++0x support something like this?
That is, if I have an enum, and want a type-compatible subtype of it....
Something along the lines of
enum Day {
Sunday,
Monday,
Tuesday,
Wednesday,
Thursday,
Friday,
Saturday
};
and I want to create a subtype that's just the weekdays (Monday through
Friday). However, I don't want to have to do casting between the two.
This is equivalent to the Ada subtype construct.
Will C++0x support something like this?