I want something like
enum EnumType {val1 = -1, val2 = 1};
enum EnumType2 {val1 = 1, val2 = -1};
In particular, val1 and val2 depend on the enumerated type–EnumType or EnumType2.
So I eventually want to be able to say something like
EnumType x = val1;
EnumType2 y = val1;
and have x and y have different values.
Is the foregoing possible?
I may be mistaken but I think the ambiguity in your example can be resolved with EnumType::val1 and EnumType2::val1