From fb6ecdf27c40654746780cb92f922655c59db19e Mon Sep 17 00:00:00 2001 From: David Blaikie Date: Sat, 21 Jan 2012 18:02:01 +0000 Subject: Remove unreachable defaults from gtest. This will ensure LLVM and Clang build -Wswitch-enum-redundant-default (an on-by-default warning I'm about to add to Clang). llvm-svn: 148639 --- llvm/utils/unittest/googletest/gtest-death-test.cc | 1 - llvm/utils/unittest/googletest/gtest.cc | 2 -- .../googletest/include/gtest/internal/gtest-death-test-internal.h | 2 -- 3 files changed, 5 deletions(-) (limited to 'llvm/utils/unittest') diff --git a/llvm/utils/unittest/googletest/gtest-death-test.cc b/llvm/utils/unittest/googletest/gtest-death-test.cc index 65893851e2d..bf7e32c2383 100644 --- a/llvm/utils/unittest/googletest/gtest-death-test.cc +++ b/llvm/utils/unittest/googletest/gtest-death-test.cc @@ -527,7 +527,6 @@ bool DeathTestImpl::Passed(bool status_ok) { } break; case IN_PROGRESS: - default: GTEST_LOG_(FATAL) << "DeathTest::Passed somehow called before conclusion of test"; } diff --git a/llvm/utils/unittest/googletest/gtest.cc b/llvm/utils/unittest/googletest/gtest.cc index 76244974115..653892404f5 100644 --- a/llvm/utils/unittest/googletest/gtest.cc +++ b/llvm/utils/unittest/googletest/gtest.cc @@ -2480,8 +2480,6 @@ static const char * TestPartResultTypeToString(TestPartResult::Type type) { #else return "Failure\n"; #endif - default: - return "Unknown result type"; } } diff --git a/llvm/utils/unittest/googletest/include/gtest/internal/gtest-death-test-internal.h b/llvm/utils/unittest/googletest/include/gtest/internal/gtest-death-test-internal.h index 1d9f83b652b..7bac2bd872b 100644 --- a/llvm/utils/unittest/googletest/include/gtest/internal/gtest-death-test-internal.h +++ b/llvm/utils/unittest/googletest/include/gtest/internal/gtest-death-test-internal.h @@ -207,8 +207,6 @@ GTEST_API_ bool ExitedUnsuccessfully(int exit_status); gtest_dt->Abort(::testing::internal::DeathTest::TEST_DID_NOT_DIE); \ break; \ } \ - default: \ - break; \ } \ } \ } else \ -- cgit v1.2.3