r342876 - Fix Wundef NDEBUG warning; NFC
Sven van Haastregt via cfe-commits
cfe-commits at lists.llvm.org
Mon Sep 24 05:12:03 PDT 2018
Author: svenvh
Date: Mon Sep 24 05:12:03 2018
New Revision: 342876
URL: http://llvm.org/viewvc/llvm-project?rev=342876&view=rev
Log:
Fix Wundef NDEBUG warning; NFC
Check for definedness of the NDEBUG macro rather than its value,
to be consistent with other uses.
Modified:
cfe/trunk/lib/Sema/ParsedAttr.cpp
Modified: cfe/trunk/lib/Sema/ParsedAttr.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/ParsedAttr.cpp?rev=342876&r1=342875&r2=342876&view=diff
==============================================================================
--- cfe/trunk/lib/Sema/ParsedAttr.cpp (original)
+++ cfe/trunk/lib/Sema/ParsedAttr.cpp Mon Sep 24 05:12:03 2018
@@ -82,7 +82,7 @@ void AttributeFactory::deallocate(Parsed
if (freeListIndex >= FreeLists.size())
FreeLists.resize(freeListIndex + 1);
-#if !NDEBUG
+#ifndef NDEBUG
// In debug mode, zero out the attribute to help find memory overwriting.
memset(Attr, 0, size);
#endif
More information about the cfe-commits
mailing list