On 7/23/21 7:38 AM, Petr Viktorin wrote:
(In both C & C++, the size of an `enum` is implementation-defined. That's unlikely to be a problem in practice, but one more point against enum.)
True, but there's always the old trick of sticking in a value that forces it to be at least 32-bit:
typedef enum { INVALID = 0, RED = 1, BLUE = 2, GREEN = 3, UNUSED = 1073741824 } color_t; //arry/
_______________________________________________ Python-Dev mailing list -- python-dev@python.org To unsubscribe send an email to python-dev-le...@python.org https://mail.python.org/mailman3/lists/python-dev.python.org/ Message archived at https://mail.python.org/archives/list/python-dev@python.org/message/3C5ANX5ONLE6OWZ4N24ENDOX2H3R5UC2/ Code of Conduct: http://python.org/psf/codeofconduct/