编译器的问题,MDK5 帮助里面给出的解决方案
This description applies to RVCT 2.2 and later.
C mode:
the warning is produced but the compiler promotes the constants to unsigned
the switch --strict always produces this message as an error.
C++ mode:
by default the out-of-range constants are promoted to unsigned without a warning and also when --strict is used
As a work around for cases where the message is an error use the following code example:
typedef enum
{
Bit31 = (int)0x80000000
} Bits;