Skip to content
This repository was archived by the owner on Aug 31, 2021. It is now read-only.

Commit 3abda9d

Browse files
committed
[CID 17042] libcore: Remove MCBinaryEncoder/Decoder API entirely.
1 parent ac71b9c commit 3abda9d

File tree

3 files changed

+1
-257
lines changed

3 files changed

+1
-257
lines changed

libcore/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ TYPE=archive
33

44
include ../rules/environment.linux.makefile
55

6-
SOURCES=core.cpp binary.cpp module.cpp thread.cpp filesystem.cpp
6+
SOURCES=core.cpp module.cpp thread.cpp filesystem.cpp
77

88
CUSTOM_DEFINES=
99

libcore/include/core.h

Lines changed: 0 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -479,44 +479,6 @@ class MCAutoCString
479479

480480
////////////////////////////////////////////////////////////////////////////////
481481

482-
struct MCBinaryEncoder;
483-
484-
bool MCBinaryEncoderCreate(MCBinaryEncoder*& r_encoder);
485-
void MCBinaryEncoderDestroy(MCBinaryEncoder *encoder);
486-
487-
void MCBinaryEncoderBorrow(MCBinaryEncoder *encoder, void*& r_buffer, uint32_t& r_buffer_length);
488-
489-
bool MCBinaryEncoderWriteBytes(MCBinaryEncoder *encoder, const void *data, uint32_t length);
490-
bool MCBinaryEncoderWriteInt32(MCBinaryEncoder *encoder, int32_t p_value);
491-
bool MCBinaryEncoderWriteUInt32(MCBinaryEncoder *encoder, uint32_t p_value);
492-
bool MCBinaryEncoderWriteCBlob(MCBinaryEncoder *encoder, const void *data, uint32_t length);
493-
bool MCBinaryEncoderWriteCString(MCBinaryEncoder *encoder, const char *cstring);
494-
495-
#ifdef _MACOSX
496-
bool MCBinaryEncoderWriteCFData(MCBinaryEncoder *encoder, CFDataRef cfdata);
497-
bool MCBinaryEncoderWriteCFString(MCBinaryEncoder *encoder, CFStringRef cfstring);
498-
#endif
499-
500-
/////////
501-
502-
struct MCBinaryDecoder;
503-
504-
bool MCBinaryDecoderCreate(const void *p_buffer, uint32_t p_length, MCBinaryDecoder*& r_decoder);
505-
void MCBinaryDecoderDestroy(MCBinaryDecoder *p_decoder);
506-
507-
bool MCBinaryDecoderReadBytes(MCBinaryDecoder *decoder, void *data, uint32_t count);
508-
bool MCBinaryDecoderReadInt32(MCBinaryDecoder *decoder, int32_t& r_value);
509-
bool MCBinaryDecoderReadUInt32(MCBinaryDecoder *decoder, uint32_t& r_value);
510-
bool MCBinaryDecoderReadCBlob(MCBinaryDecoder *decoder, void*& r_data, uint32_t& r_length);
511-
bool MCBinaryDecoderReadCString(MCBinaryDecoder *self, char *&r_cstring);
512-
513-
#ifdef _MACOSX
514-
bool MCBinaryDecoderReadCFData(MCBinaryDecoder *decoder, CFDataRef& r_value);
515-
bool MCBinaryDecoderReadCFString(MCBinaryDecoder *decoder, CFStringRef& r_value);
516-
#endif
517-
518-
////////////////////////////////////////////////////////////////////////////////
519-
520482
inline uint32_t MCMin(uint32_t a, uint32_t b) { return a < b ? a : b; }
521483
inline uint32_t MCMax(uint32_t a, uint32_t b) { return a > b ? a : b; }
522484
inline int32_t MCMin(int32_t a, int32_t b) { return a < b ? a : b; }

libcore/src/binary.cpp

Lines changed: 0 additions & 218 deletions
This file was deleted.

0 commit comments

Comments
 (0)