Skip to content

Commit

Permalink
common: add message to deprecated macros
Browse files Browse the repository at this point in the history
  • Loading branch information
edoardolombardi committed Sep 19, 2022
1 parent 9765f09 commit 7944d01
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/common/compiler.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -75,10 +75,13 @@ do { \
*/
#if defined __GNUC__
# define BITPIT_DEPRECATED(func) func __attribute__ ((deprecated))
# define BITPIT_DEPRECATED_FOR(func, replacement) func __attribute__ ((deprecated(" Use " #replacement)))
#elif defined __clang__
# define BITPIT_DEPRECATED(func) func __attribute__ ((deprecated))
# define BITPIT_DEPRECATED_FOR(func, replacement) func __attribute__ ((deprecated(" Use " #replacement)))
#elif defined(_MSC_VER)
#define BITPIT_DEPRECATED(func) __declspec(deprecated) func
#define BITPIT_DEPRECATED_FOR(func), replacement __declspec(deprecated(" Use " #replacement)) func
#else
# pragma message("WARNING: You need to implement DEPRECATED for this compiler")
# define BITPIT_DEPRECATED(func) func
Expand Down

0 comments on commit 7944d01

Please sign in to comment.