Fixes warnings when built by GCC with -Wswitch-default. Original patch by Zhixu Liu (zhixu.liu@gmail.com).
This commit is contained in:
@@ -176,6 +176,8 @@ GTEST_API_ bool ExitedUnsuccessfully(int exit_status);
|
||||
gtest_dt->Abort(::testing::internal::DeathTest::TEST_DID_NOT_DIE); \
|
||||
break; \
|
||||
} \
|
||||
default: \
|
||||
break; \
|
||||
} \
|
||||
} \
|
||||
} else \
|
||||
|
||||
@@ -535,7 +535,7 @@
|
||||
#ifdef __INTEL_COMPILER
|
||||
#define GTEST_AMBIGUOUS_ELSE_BLOCKER_
|
||||
#else
|
||||
#define GTEST_AMBIGUOUS_ELSE_BLOCKER_ switch (0) case 0: // NOLINT
|
||||
#define GTEST_AMBIGUOUS_ELSE_BLOCKER_ switch (0) case 0: default: // NOLINT
|
||||
#endif
|
||||
|
||||
// Use this annotation at the end of a struct/class definition to
|
||||
|
||||
Reference in New Issue
Block a user