Skip to content

Conversation

pespinho
Copy link

@pespinho pespinho commented Mar 5, 2024

Hello Kieselsteini,

The current implementation does not support encoding nil as values of a table or an empty map, which are sometimes needed for complying to some protocol specifications, e.g. MessagePack-RPC.

The changes in this pull request target adding these two features to the library.

This is achieved by adding two objects to the library that represents the two MessagePack values (NIL and EMPTY_MAP).
Since they have an unique address in Lua, it is possible to identify the intent of the user of encoding these values.

What do you think of this solution?

Best regards
Pespinho

@pespinho pespinho marked this pull request as draft March 5, 2024 12:12
@pespinho pespinho changed the title Add encoding of nil values in tables and of empty objects Add encoding of nil values in tables and of empty maps Mar 5, 2024
@pespinho pespinho marked this pull request as ready for review March 5, 2024 14:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant