Skip to content

Commit eb3dbf3

Browse files
committed
CATCH: silence Visual Studio warnings
1 parent fce6f0c commit eb3dbf3

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

unit/testing-utils/catch.hpp

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,14 @@
4444

4545
# pragma GCC diagnostic push
4646
# pragma GCC diagnostic ignored "-Wpadded"
47+
#elif defined _MSC_VER
48+
#include <util/pragma_push.def>
49+
#pragma warning(disable:4061)
50+
// enumerator not explicitly handled by case label
51+
#pragma warning(disable:4388)
52+
// signed/unsigned mismatch
53+
#pragma warning(disable:4668)
54+
// using #if/#elif on undefined macro
4755
#endif
4856
#if defined(CATCH_CONFIG_MAIN) || defined(CATCH_CONFIG_RUNNER)
4957
# define CATCH_IMPL
@@ -11203,6 +11211,8 @@ namespace Catch {
1120311211

1120411212
#ifdef __clang__
1120511213
#pragma clang diagnostic pop
11214+
#elif defined _MSC_VER
11215+
#include <util/pragma_pop.def>
1120611216
#endif
1120711217

1120811218
#endif

0 commit comments

Comments
 (0)