commit 4206ad194ef21a31cfb8d20acee67159a7290413
parent e73e19e0251e2bf8a4707ea1f33239f6db35e0c4
Author: JP Cimalando <jp-dev@inbox.ru>
Date: Thu, 7 Feb 2019 21:23:33 +0100
Provide a DISTRHO_DEPRECATED attribute
Diffstat:
1 file changed, 9 insertions(+), 0 deletions(-)
diff --git a/distrho/src/DistrhoDefines.h b/distrho/src/DistrhoDefines.h
@@ -66,6 +66,15 @@
# define nullptr NULL
#endif
+/* Define DISTRHO_DEPRECATED */
+#if defined(__GNUC__)
+# define DISTRHO_DEPRECATED __attribute__((deprecated))
+#elif defined(_MSC_VER)
+# define DISTRHO_DEPRECATED __declspec(deprecated)
+#else
+# define DISTRHO_DEPRECATED
+#endif
+
/* Define DISTRHO_SAFE_ASSERT* */
#define DISTRHO_SAFE_ASSERT(cond) if (! (cond)) d_safe_assert(#cond, __FILE__, __LINE__);
#define DISTRHO_SAFE_ASSERT_BREAK(cond) if (! (cond)) { d_safe_assert(#cond, __FILE__, __LINE__); break; }