chakra-core/ChakraCore

Make number serialization compatible with V8 (and new IETF spec draft)

Open

#149 ouverte le 20 janv. 2016

Voir sur GitHub
 (20 commentaires) (0 réactions) (0 assignés)JavaScript (1 374 forks)batch import
BugCompatibilitySeverity: 2Suggestionhelp wanted

Métriques du dépôt

Stars
 (9 000 stars)
Métriques de merge PR
 (Aucune PR mergée en 30 j)

Description

In order to create signed JavaScript objects, you need to normalize data.

The JCS specification https://cyberphone.github.io/openkeystore/resources/docs/jcs.html#ECMAScript_Compatibility_Mode accomplish this "automatically" by relying on ES6 for property order (which Chakra implements), but also depends on the extended number formatting algorithm used in the Google V8 engine which after testing with 100 million of random and selected values appears to be used by Chrome, Firefox, and Safari as well as "node.js".

Browser test program: http://webpki.org/ietf/es6numberbrowsertest.html

10 million value test file: http://webpki.org/ietf/es6testfile.txt

Although JCS does not (a this stage) represent a standard, the core concept will most likely become a de-facto standard due to its simplicity.

Guide contributeur