JulesAU/node-msgpack — pull request #2 by sugendran (2012-02-06 22:25:43+00:00)
Title: 64bit ints don't pack/upack properly

Integers in javascript are 32bit values so unpacking to one fails for int64 values. Also updated the test pack to test this.

simple test is:

var msgpack2 = require("msgpack2"); var bignum = Date.now(); var packed = msgpack2.pack(bignum); var unpacked = msgpack2.unpack(packed); require("assert").equal(bignum, unpacked);

var msgpack2 = require("msgpack2"); var bignum = Date.now() + 0.1; var packed = msgpack2.pack(bignum); var unpacked = msgpack2.unpack(packed); require("assert").equal(bignum, unpacked);