chore(Common/Misc): Replace old macros with modern C++ attributes (#6462)
* chore(Common/Misc): Replace old macros with modern C++ attributes * cherry-pick commit (https://github.com/TrinityCore/TrinityCore/commit/5ae2a0f47d323fadcfebf44c7b6ec11a3f91c75a) Co-Authored-By: Giacomo Pozzoni <giacomopoz@gmail.com> * fix build Co-authored-by: Giacomo Pozzoni <giacomopoz@gmail.com>
This commit is contained in:
@@ -26,16 +26,8 @@
|
||||
#if AC_PLATFORM == AC_PLATFORM_WINDOWS
|
||||
# define ACORE_PATH_MAX MAX_PATH
|
||||
# define _USE_MATH_DEFINES
|
||||
# ifndef DECLSPEC_NORETURN
|
||||
# define DECLSPEC_NORETURN __declspec(noreturn)
|
||||
# endif //DECLSPEC_NORETURN
|
||||
# ifndef DECLSPEC_DEPRECATED
|
||||
# define DECLSPEC_DEPRECATED __declspec(deprecated)
|
||||
# endif //DECLSPEC_DEPRECATED
|
||||
#else //AC_PLATFORM != AC_PLATFORM_WINDOWS
|
||||
# define ACORE_PATH_MAX PATH_MAX
|
||||
# define DECLSPEC_NORETURN
|
||||
# define DECLSPEC_DEPRECATED
|
||||
#endif //AC_PLATFORM
|
||||
|
||||
#if !defined(COREDEBUG)
|
||||
@@ -48,13 +40,9 @@
|
||||
#endif //!COREDEBUG
|
||||
|
||||
#if AC_COMPILER == AC_COMPILER_GNU
|
||||
# define ATTR_NORETURN __attribute__((noreturn))
|
||||
# define ATTR_PRINTF(F, V) __attribute__ ((format (printf, F, V)))
|
||||
# define ATTR_DEPRECATED __attribute__((deprecated))
|
||||
#else //AC_COMPILER != AC_COMPILER_GNU
|
||||
# define ATTR_NORETURN
|
||||
# define ATTR_PRINTF(F, V)
|
||||
# define ATTR_DEPRECATED
|
||||
#endif //AC_COMPILER == AC_COMPILER_GNU
|
||||
|
||||
#ifdef ACORE_API_USE_DYNAMIC_LINKING
|
||||
|
||||
Reference in New Issue
Block a user