]> granicus.if.org Git - icu/commitdiff
ICU-21064 Fix declspec macro conflict on clang.
authorGregorio Litenstein <g.litenstein@gmail.com>
Thu, 5 Aug 2021 06:02:32 +0000 (02:02 -0400)
committerJeff Genovy <29107334+jefgen@users.noreply.github.com>
Mon, 16 Aug 2021 18:06:46 +0000 (11:06 -0700)
icu4c/source/common/unicode/platform.h

index cb3a833fefc9b1dc515cf55f8fd9b80f3543ee47..b7e514442cedba995977f3a22726f96af1d4718c 100644 (file)
@@ -814,8 +814,8 @@ namespace std {
     /* Use the predefined value. */
 #elif defined(U_STATIC_IMPLEMENTATION)
 #   define U_EXPORT
-#elif defined(_MSC_VER) || (UPRV_HAS_DECLSPEC_ATTRIBUTE(dllexport) && \
-                            UPRV_HAS_DECLSPEC_ATTRIBUTE(dllimport))
+#elif defined(_MSC_VER) || (UPRV_HAS_DECLSPEC_ATTRIBUTE(__dllexport__) && \
+                            UPRV_HAS_DECLSPEC_ATTRIBUTE(__dllimport__))
 #   define U_EXPORT __declspec(dllexport)
 #elif defined(__GNUC__)
 #   define U_EXPORT __attribute__((visibility("default")))
@@ -839,8 +839,8 @@ namespace std {
 
 #ifdef U_IMPORT
     /* Use the predefined value. */
-#elif defined(_MSC_VER) || (UPRV_HAS_DECLSPEC_ATTRIBUTE(dllexport) && \
-                            UPRV_HAS_DECLSPEC_ATTRIBUTE(dllimport))
+#elif defined(_MSC_VER) || (UPRV_HAS_DECLSPEC_ATTRIBUTE(__dllexport__) && \
+                            UPRV_HAS_DECLSPEC_ATTRIBUTE(__dllimport__))
     /* Windows needs to export/import data. */
 #   define U_IMPORT __declspec(dllimport)
 #else