msgpack/msgpack-objectivec — pull request #5 by csaftoiu (2013-10-01 03:31:52+00:00)
Title: Add support and options for parsing and packing NSData

For my use case I need to ship around raw bytes that aren't utf8-strings. I added support for this.

The default behavior is almost the same: it attempts to parse the bytes into a utf8-string. However, if it fails, it'll raise an exception instead of either returning nil, not adding a key to a dictionary, or raising an exception when trying to add nil to an NSArray.

Additionally you can specify 3 different behaviors: try to parse as string but fallback on NSData, try to parse as string but fallback on NSNull, or always parse as NSData.