monotone-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Monotone-devel] serialization format


From: Markus Wanner
Subject: Re: [Monotone-devel] serialization format
Date: Wed, 6 Apr 2016 07:28:39 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.6.0

On 04/06/2016 05:26 AM, J Decker wrote:
> If the structures might mutate with time something like json is pretty brief.
> if you have high reliability, sqlite for instance will store a blob
> with only \0 for the 0  and \\ for \ ...

JSON doesn't handle binary welll, it's a text format. Usually, base64 is
used for binary data inside JSON - which is neither human readable nor
space efficient.

> which results in a copy or shift of data but only a simple comparison
> if '\\'   kinda like base 254 sorta :)
> depending on what character happens least you could replace <nul> for
> <del> or something ...

That's nonsense, according to http://stackoverflow.com/a/1443240, the
JSON spec supports only 94 Unicode characters that can be represented as
one byte (in UTF-8).

Nor is there any canonical *and* human readable variant.

If human readable, I'd currently prefer to try something canonical
that's still valid YAML.

Kind Regards

Markus Wanner




reply via email to

[Prev in Thread] Current Thread [Next in Thread]