1
0
mirror of https://github.com/cc65/cc65.git synced 2024-11-18 00:07:21 +00:00

Guard MSVC pragma with ifdef _MSC_VER

Fix broken travis-ci with gcc -Werror [-Werror=unknown-pragmas].
This commit is contained in:
Jesse Rosenstock 2020-07-08 22:46:40 +02:00 committed by Oliver Schmidt
parent 9e5b8d99a3
commit 2c16453a9f

View File

@ -776,7 +776,9 @@ static SymEntry* ParseStructDecl (const char* Name)
** about unary negation of unsigned, but it's intended.
** Disable the warning for the next line only.
*/
#ifdef _MSC_VER
#pragma warning(disable: 4146)
#endif
unsigned PaddingBits = -BitOffs % CHAR_BITS;
/* We need an anonymous name */