From 8b4a301d6088cade779c4097a5f34fe743ebaadd Mon Sep 17 00:00:00 2001 From: JP Cimalando Date: Thu, 7 Feb 2019 21:24:00 +0100 Subject: [PATCH] Provide a DISTRHO_DEPRECATED attribute --- distrho/src/DistrhoDefines.h | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/distrho/src/DistrhoDefines.h b/distrho/src/DistrhoDefines.h index c14cfb8a..f16e44d5 100644 --- 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; }