aboutsummaryrefslogtreecommitdiff
path: root/Foundation
diff options
context:
space:
mode:
authorGravatar gtm.daemon <gtm.daemon@7dc7ac4e-7543-0410-b95c-c1676fc8e2a3>2013-06-24 21:30:11 +0000
committerGravatar gtm.daemon <gtm.daemon@7dc7ac4e-7543-0410-b95c-c1676fc8e2a3>2013-06-24 21:30:11 +0000
commit6017afdfd4d0b3d3070980b8a540acbc1c5e242a (patch)
tree7d167a838ff25c02c7f17e51338ae289d1d30c03 /Foundation
parentcba40d9e2e1cc1d078e855b43f21c82bb0d7d275 (diff)
Deprecate GTMObjectSingleton for 10.9/iOS 7 to force removal of the dependency from projects using it.
DELTA=8 (7 added, 0 deleted, 1 changed)
Diffstat (limited to 'Foundation')
-rw-r--r--Foundation/GTMObjectSingleton.h9
1 files changed, 8 insertions, 1 deletions
diff --git a/Foundation/GTMObjectSingleton.h b/Foundation/GTMObjectSingleton.h
index eeb9ec7..0932652 100644
--- a/Foundation/GTMObjectSingleton.h
+++ b/Foundation/GTMObjectSingleton.h
@@ -18,7 +18,7 @@
//
//
-// This file is still around for compatibility with apps relying on its macro,
+// This file has been kept around for compatibility with apps relying on its macro,
// but given how simple this is, there is not a compelling reason for any app to
// use this macro.
//
@@ -31,6 +31,13 @@
// (with no trailing semicolon)
//
+#include <AvailabilityMacros.h>
+
+#if (defined(__IPHONE_7_0) && (__IPHONE_OS_VERSION_MAX_ALLOWED >= __IPHONE_7_0)) \
+ || (defined(MAC_OS_X_VERSION_10_9) && (MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_9))
+#error "GTMOBJECT_SINGLETON_BOILERPLATE is deprecated; change this in your sources to a class method using dispatch_once."
+#endif
+
#if NS_BLOCKS_AVAILABLE
#define GTMOBJECT_SINGLETON_BOILERPLATE(_object_name_, _shared_obj_name_) \