I came across this question about the underlying types of enums, where an answers quotes Standard C++ 7.2/5 as:
The underlying type of an enumeration is an integral type that can represent all the enumerator values defined in the enumeration. It is implementation-defined which integral type is used as the underlying type for an enumeration except that the underlying type shall not be larger than int unless the value of an enu- merator cannot fit in an int or unsigned int.
This is pretty clear for all reasonable cases. But what happens if I make an enum so ridiculously large that it can't even fit in a long long?
(I don't know why this would ever happen in practice, but maybe I'm feeling destructive and have a free afternoon)
Is this behavior defined by the standard?