MSVC: lower C4100 warning level from 4 to 3
This better aligns with OSX/Linux warnings. Although `__pragma(warning(suppress:4100))` is not the same as `__attribute__((__unused__))` in gcc (which only affects the attribute instead of the line), it still seems to be better to use it than to hide the warning entirely.
This commit is contained in:
committed by
Germano Cavalcante
parent
f4db58844d
commit
db4e7616f3
@@ -10,6 +10,9 @@
|
||||
|
||||
#ifdef __GNUC__
|
||||
# define UNUSED(x) UNUSED_##x __attribute__((__unused__))
|
||||
#elif defined(_MSC_VER)
|
||||
/* NOTE: This suppresses the warning for the line, not the attribute. */
|
||||
# define UNUSED(x) UNUSED_##x __pragma(warning(suppress : 4100))
|
||||
#else
|
||||
# define UNUSED(x) UNUSED_##x
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user