Re: "Number" in RDF Dataset Normalization

On 2017-04-14 21:45, Dave Longley wrote:
> On 04/14/2017 03:26 PM, Anders Rundgren wrote:
>> Hi All,
>>
>> I tried to read this document since JSON normalization/canonicalization
>> is something that interest a lot of people:
>> http://json-ld.github.io/normalization/spec/
>>
>> It is possible that I have read it too fast but I cannot find any
>> handling of Number which actually is a major PITA.
>> Other aspects of JSON (not RDF) normalization is something any habile
>> programmer should be able handle.
>
> The RDF Dataset Normalization spec is written to operate on an abstract
> representation of RDF. JSON-LD can be deserialized to RDF using the
> JSON-LD API spec (which is a W3C Rec). That spec mentions how it
> handles numbers here:
>
> https://www.w3.org/TR/json-ld-api/#data-round-tripping

Thanx Dave!

I'm surprised that the JOSE folks never referred to this.

LD doesn't return exactly the same result as ES6 serialization
for non-normalized numbers but that is probably not a major
issue because then you are pretty on the limit anyway.

4.9E-324 is converted to 5e-324 in ES6 and in LD to 4.940656458412465E-324

Anders

>
>

Received on Friday, 14 April 2017 20:19:55 UTC