Skip to content

Commit 41b2fc2

Browse files
committed
wolfssl/wolfcrypt/wc_port.h: add WC_DEPRECATED() definitions for _MSC_VER < 1400.
1 parent d210b92 commit 41b2fc2

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

wolfssl/wolfcrypt/wc_port.h

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -95,9 +95,15 @@
9595
#elif defined(__WATCOMC__)
9696
/* Watcom macro needs to expand to something, here just a comment: */
9797
#define WC_DEPRECATED(msg) /* null expansion */
98-
#elif defined(_MSC_VER) || defined(__MINGW32__) || defined(__CYGWIN__) || \
99-
defined(_WIN32_WCE)
98+
#elif (defined(_MSC_VER) && _MSC_VER >= 1400) || defined(__MINGW32__) || \
99+
defined(__CYGWIN__) || defined(_WIN32_WCE)
100100
#define WC_DEPRECATED(msg) __declspec(deprecated(msg))
101+
#elif defined(_MSC_VER)
102+
#ifdef __cplusplus
103+
#define WC_DEPRECATED(msg) __declspec(deprecated)
104+
#else
105+
#define WC_DEPRECATED(msg) __pragma(deprecated)
106+
#endif
101107
#elif (defined(__GNUC__) && (__GNUC__ >= 4)) || \
102108
defined(__IAR_SYSTEMS_ICC__)
103109
#define WC_DEPRECATED(msg) __attribute__((deprecated))

0 commit comments

Comments
 (0)