[libunwind] r266916 - unwind: remove a second instance of -Wexpansion-to-defined
Saleem Abdulrasool via cfe-commits
cfe-commits at lists.llvm.org
Wed Apr 20 13:54:55 PDT 2016
Author: compnerd
Date: Wed Apr 20 15:54:55 2016
New Revision: 266916
URL: http://llvm.org/viewvc/llvm-project?rev=266916&view=rev
Log:
unwind: remove a second instance of -Wexpansion-to-defined
Remove the use of undefined behaviour in the c preprocessor by always defining
the value according to the state that was being checked. NFC.
Modified:
libunwind/trunk/src/config.h
Modified: libunwind/trunk/src/config.h
URL: http://llvm.org/viewvc/llvm-project/libunwind/trunk/src/config.h?rev=266916&r1=266915&r2=266916&view=diff
==============================================================================
--- libunwind/trunk/src/config.h (original)
+++ libunwind/trunk/src/config.h Wed Apr 20 15:54:55 2016
@@ -86,11 +86,14 @@
#endif
#endif
-#define _LIBUNWIND_BUILD_ZERO_COST_APIS \
- (defined(__i386__) || defined(__x86_64__) || \
- (!defined(__APPLE__) && defined(__arm__)) || \
- (defined(__arm64__) || defined(__aarch64__)) || \
- (defined(__APPLE__) && defined(__mips__)))
+#if defined(__i386__) || defined(__x86_64__) || \
+ (!defined(__APPLE__) && defined(__arm__)) || \
+ (defined(__arm64__) || defined(__aarch64__)) || \
+ (defined(__APPLE__) && defined(__mips__))
+#define _LIBUNWIND_BUILD_ZERO_COST_APIS 1
+#else
+#define _LIBUNWIND_BUILD_ZERO_COST_APIS 0
+#endif
// Macros that define away in non-Debug builds
#ifdef NDEBUG
More information about the cfe-commits
mailing list