W3C home > Mailing lists > Public > public-rdf-comments@w3.org > September 2012

RE: XSD datatypes in JSON-LD (was: Re: Use of XSD namespace in RDF recommendations)

From: Markus Lanthaler <markus.lanthaler@gmx.net>
Date: Wed, 5 Sep 2012 12:20:05 +0200
To: "'Richard Cyganiak'" <richard@cyganiak.de>
Cc: "'Gregg Kellogg'" <gregg@greggkellogg.net>, "'public-rdf-comments Comments'" <public-rdf-comments@w3.org>
Message-ID: <00ef01cd8b50$05b64bd0$1122e370$@lanthaler@gmx.net>
On Wednesday, September 05, 2012 11:50 AM, Richard Cyganiak wrote:

> Why not convert "5"^^xsd:double to a JSON-native 5.0? This would allow
> round-tripping, and no useNativeTypes flag is necessary.

The problem is that JSON parsera automatically "normalize" a 5.0 to 5 during
parsing. Since we reuse existing JSON parsers, there's no way for us to
check whether there was a .0 or not.

Markus Lanthaler
Received on Wednesday, 5 September 2012 10:20:42 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 20:29:54 UTC