[m-dev.] Binary data and UTF-8

Peter Wang novalazy at gmail.com
Fri May 11 13:31:42 AEST 2012


On Fri, 11 May 2012 11:59:26 +1000, Paul Bone <pbone at csse.unimelb.edu.au> wrote:
> 
> There's an open question on stack exchange today about parsing binary data and
> UTF8.
> 
> I'm not sure on the answer, I'd just be guessing.  Peter W, would you mind answering the question?
> 
> http://stackoverflow.com/questions/10543654/what-is-a-good-data-type-for-representing-arbitrary-binary-data

I see you answered.  I don't have an account anyway.

I usually end up using a custom foreign type.  One thing which prevented
me from using bitmap (again) is a lack of distinction between size and
capacity.  That would allow a bitmap to grow efficiently on append.

And my general complaint: working with bits is annoying and error prone.
We don't necessarily need a new type, just a module that provides a
byte-oriented interface on top of bitmap.

Peter
--------------------------------------------------------------------------
mercury-developers mailing list
Post messages to:       mercury-developers at csse.unimelb.edu.au
Administrative Queries: owner-mercury-developers at csse.unimelb.edu.au
Subscriptions:          mercury-developers-request at csse.unimelb.edu.au
--------------------------------------------------------------------------



More information about the developers mailing list