Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions ext/msgpack/packer.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,15 +31,15 @@ typedef struct msgpack_packer_t msgpack_packer_t;
struct msgpack_packer_t {
msgpack_buffer_t buffer;

bool compatibility_mode;
bool has_bigint_ext_type;
bool has_symbol_ext_type;

ID to_msgpack_method;
VALUE to_msgpack_arg;

VALUE buffer_ref;

bool compatibility_mode;
bool has_bigint_ext_type;
bool has_symbol_ext_type;

/* options */
bool comaptibility_mode;
Comment on lines +39 to 44
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Btw, if you use a bitfield, you can even turn this from 16B down to 8B

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm never too sure how bitfields impact performance. Probably negligible, but I only made this change because it was an obvious small waste.

msgpack_packer_ext_registry_t ext_registry;
Expand Down