diff options
author | kbinani <kbinani.bt@gmail.com> | 2015-09-04 13:41:12 +0900 |
---|---|---|
committer | kbinani <kbinani.bt@gmail.com> | 2015-09-04 14:00:16 +0900 |
commit | 9a06c8000e95553cb7910487882c195e31b50d85 (patch) | |
tree | bf4c7dfa61acd2d20ffdf4949c2ec1bb23511bbc /src | |
parent | 0087da9d4775f79c67362cc89c653f3a33a9bae2 (diff) | |
download | protobuf-9a06c8000e95553cb7910487882c195e31b50d85.tar.gz protobuf-9a06c8000e95553cb7910487882c195e31b50d85.tar.bz2 protobuf-9a06c8000e95553cb7910487882c195e31b50d85.zip |
Rename 'BYTE_SIZE' macro to 'GOOGLE_PROTOBUF_BYTE_SIZE'
Xcode raises warning that says "'BYTE_SIZE' macro redefined".
The original 'BYTE_SIZE' macro definition is here, for example:
'/Applications/Xcode/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include/mach/vm_param.h'
Diffstat (limited to 'src')
-rw-r--r-- | src/google/protobuf/map_type_handler.h | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/src/google/protobuf/map_type_handler.h b/src/google/protobuf/map_type_handler.h index 5040e605..f8ad7584 100644 --- a/src/google/protobuf/map_type_handler.h +++ b/src/google/protobuf/map_type_handler.h @@ -272,24 +272,24 @@ MapTypeHandler<WireFormatLite::TYPE_MESSAGE, Type>::ByteSize( return WireFormatLite::MessageSizeNoVirtual(value); } -#define BYTE_SIZE(FieldType, DeclaredType) \ +#define GOOGLE_PROTOBUF_BYTE_SIZE(FieldType, DeclaredType) \ template <typename Type> \ inline int MapTypeHandler<WireFormatLite::TYPE_##FieldType, Type>::ByteSize( \ const MapEntryAccessorType& value) { \ return WireFormatLite::DeclaredType##Size(value); \ } -BYTE_SIZE(STRING, String) -BYTE_SIZE(BYTES , Bytes) -BYTE_SIZE(INT64 , Int64) -BYTE_SIZE(UINT64, UInt64) -BYTE_SIZE(INT32 , Int32) -BYTE_SIZE(UINT32, UInt32) -BYTE_SIZE(SINT64, SInt64) -BYTE_SIZE(SINT32, SInt32) -BYTE_SIZE(ENUM , Enum) - -#undef BYTE_SIZE +GOOGLE_PROTOBUF_BYTE_SIZE(STRING, String) +GOOGLE_PROTOBUF_BYTE_SIZE(BYTES , Bytes) +GOOGLE_PROTOBUF_BYTE_SIZE(INT64 , Int64) +GOOGLE_PROTOBUF_BYTE_SIZE(UINT64, UInt64) +GOOGLE_PROTOBUF_BYTE_SIZE(INT32 , Int32) +GOOGLE_PROTOBUF_BYTE_SIZE(UINT32, UInt32) +GOOGLE_PROTOBUF_BYTE_SIZE(SINT64, SInt64) +GOOGLE_PROTOBUF_BYTE_SIZE(SINT32, SInt32) +GOOGLE_PROTOBUF_BYTE_SIZE(ENUM , Enum) + +#undef GOOGLE_PROTOBUF_BYTE_SIZE #define FIXED_BYTE_SIZE(FieldType, DeclaredType) \ template <typename Type> \ |