Hacker News new | past | comments | ask | show | jobs | submit login

> The core idea is: many serializations, one underlying data structure/object graph.

Then why is UTF-8 even mentioned? Or time zone offsets, for that matter?




So it's possible to specify a rigorous set of tests cases that, ideally if all are passed, can be used to certify a conforming implementation.

In other words, to solve this problem:

http://seriot.ch/parsing_json.php

While in some cases it might make sense to relax some of the requirements, I'm a fan of keeping things simple. Call me one of those crazy people who thinks Postel's Law is wrong.

TJSON specifies a set of test cases for this purpose here:

https://raw.githubusercontent.com/tjson/tjson-spec/master/dr...

I prefer to specify things in such a way that it's relatively easy to specify a test suite that covers all of the corner cases.

A secondary goal of TJSON is to produce a stricter format, so I'd prefer to start with additional strictness requirements, and relax them if a reasonable case can be made.




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: