[llvm] r240553 - ADTTests: merge #ifdef checks from r240436.

Alex Lorenz arphaman at gmail.com
Wed Jun 24 10:05:04 PDT 2015


Author: arphaman
Date: Wed Jun 24 12:05:04 2015
New Revision: 240553

URL: http://llvm.org/viewvc/llvm-project?rev=240553&view=rev
Log:
ADTTests: merge #ifdef checks from r240436.

This commit merges the #ifdef and #ifndef checks into one #if, as
suggested by Duncan P. N. Exon Smith.

Modified:
    llvm/trunk/unittests/ADT/APSIntTest.cpp

Modified: llvm/trunk/unittests/ADT/APSIntTest.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/unittests/ADT/APSIntTest.cpp?rev=240553&r1=240552&r2=240553&view=diff
==============================================================================
--- llvm/trunk/unittests/ADT/APSIntTest.cpp (original)
+++ llvm/trunk/unittests/ADT/APSIntTest.cpp Wed Jun 24 12:05:04 2015
@@ -151,8 +151,7 @@ TEST(APSIntTest, FromString) {
   EXPECT_EQ(APSInt("-1234").getExtValue(), -1234);
 }
 
-#ifdef GTEST_HAS_DEATH_TEST
-#ifndef NDEBUG
+#if defined(GTEST_HAS_DEATH_TEST) && !defined(NDEBUG)
 
 TEST(APSIntTest, StringDeath) {
   EXPECT_DEATH(APSInt(""), "Invalid string length");
@@ -160,6 +159,5 @@ TEST(APSIntTest, StringDeath) {
 }
 
 #endif
-#endif
 
 } // end anonymous namespace





More information about the llvm-commits mailing list