forked from PoomSmart/YouTubeHeader
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathGPBBootstrap.h
57 lines (44 loc) · 1.36 KB
/
GPBBootstrap.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
#import <stdint.h>
#ifndef GPBOBJC_SKIP_MESSAGE_TEXTFORMAT_EXTRAS
#define GPBOBJC_SKIP_MESSAGE_TEXTFORMAT_EXTRAS 0
#endif
#if !__has_feature(objc_fixed_enum)
#error All supported Xcode versions should support objc_fixed_enum.
#endif
#if (defined(__cplusplus) && __cplusplus && __cplusplus < 201103L)
#define GPB_ENUM(X) \
enum X : int32_t X; \
enum X : int32_t
#else
#define GPB_ENUM(X) NS_ENUM(int32_t, X)
#endif
#define GPB_ENUM_FWD_DECLARE(X) enum X : int32_t
#if !defined(DEBUG)
#define GPB_INLINE static __inline__ __attribute__((always_inline))
#else
#define GPB_INLINE static __inline__
#endif
#ifndef GPB_UNSAFE_UNRETAINED
#if __has_feature(objc_arc)
#define GPB_UNSAFE_UNRETAINED __unsafe_unretained
#else
#define GPB_UNSAFE_UNRETAINED
#endif
#endif
#ifndef GPB_DEPRECATED
#define GPB_DEPRECATED __attribute__((deprecated))
#endif
#ifndef GPB_DEPRECATED_MSG
#if __has_extension(attribute_deprecated_with_message)
#define GPB_DEPRECATED_MSG(msg) __attribute__((deprecated(msg)))
#else
#define GPB_DEPRECATED_MSG(msg) __attribute__((deprecated))
#endif
#endif
#define GPB_METHOD_FAMILY_NONE __attribute__((objc_method_family(none)))
#ifndef GPB_FINAL
#define GPB_FINAL __attribute__((objc_subclassing_restricted))
#endif
#define GOOGLE_PROTOBUF_OBJC_VERSION 30007
#define GOOGLE_PROTOBUF_OBJC_MIN_SUPPORTED_VERSION 30001
#define GOOGLE_PROTOBUF_OBJC_GEN_VERSION 30001