Skip to content

Repository files navigation

lua-msgpack

Lua MsgPack library written in C.

Install

  1. Clone the code to the 3rd directory.

  2. Run the make build command to start compiling.

  3. If there are no errors, the compilation is successful.

Usage

localmsgpack=require"msgpack"

1. encode

localmsgpack=require"msgpack"-- mapprint(msgpack.encode { a=1, b=2, c=3, list= { 'a', 'b', 'c' } })
-- arrayprint(msgpack.encode { true, false, null, 1, 2.2, "admin", list= { 1, 23}, map= { a=1} })

2. decode

require"utils"localmsgpack=require"msgpack"var_dump(msgpack.decode('\x82\xa1a\xc2\xa1b\xc3'))
var_dump(msgpack.decode('\x92\xc2\xc3'))

LICENSE

MIT

About

Lua MsgPack library written in C.

Topics

Resources

Stars

1 star

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages