From 21dbc29ad10e6acaa77c6ffa93a6f30b155dbc97 Mon Sep 17 00:00:00 2001 From: mannewalis Date: Tue, 17 Feb 2015 12:19:36 -0800 Subject: [PATCH] adding CC_DEPRECATE(version) macro --- cocos/platform/CCPlatformMacros.h | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/cocos/platform/CCPlatformMacros.h b/cocos/platform/CCPlatformMacros.h index 3e321cdff6..8a50b7a5ba 100644 --- a/cocos/platform/CCPlatformMacros.h +++ b/cocos/platform/CCPlatformMacros.h @@ -271,6 +271,13 @@ public: virtual void set##funName(varType var) \ #define CC_DEPRECATED_ATTRIBUTE #endif +/* + * macro to mark things deprecated as of a particular version + * can be used with artibrary parameters which are thrown away + * e.g. CC_DEPRECATED(4.0) or CC_DEPRECATED(4.0, "not going to need this anymore") etc. + */ +#define CC_DEPRECATED(...) CC_DEPRECATED_ATTRIBUTE + /* * only certain compiler support __attribute__((format)) * formatPos - 1-based position of format string argument