Re: [Json] Limitations on number size?

Francis Galiegue <fgaliegue@gmail.com> Thu, 11 July 2013 20:47 UTC

Return-Path: <fgaliegue@gmail.com>
X-Original-To: json@ietfa.amsl.com
Delivered-To: json@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 86D0A21F9FC3 for <json@ietfa.amsl.com>; Thu, 11 Jul 2013 13:47:28 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.6
X-Spam-Level:
X-Spam-Status: No, score=-2.6 tagged_above=-999 required=5 tests=[BAYES_00=-2.599, NO_RELAYS=-0.001]
Received: from mail.ietf.org ([12.22.58.30]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id I8hFK8ZwS9it for <json@ietfa.amsl.com>; Thu, 11 Jul 2013 13:47:28 -0700 (PDT)
Received: from mail-ee0-x236.google.com (mail-ee0-x236.google.com [IPv6:2a00:1450:4013:c00::236]) by ietfa.amsl.com (Postfix) with ESMTP id 9F16921F9FCF for <json@ietf.org>; Thu, 11 Jul 2013 13:47:27 -0700 (PDT)
Received: by mail-ee0-f54.google.com with SMTP id t10so5838585eei.13 for <json@ietf.org>; Thu, 11 Jul 2013 13:47:26 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=FzFVPZC+h6YiBSWPCLr/GDPERuFCLmX/2YYo5Vo+8H0=; b=KgqIALjwAXrcahkG7n4hjqRPesUCAMYnGoZxpzNlLH/hCR4GvbZi2qKyUVjjrAOeff vXZt8mqwPXa8FgkHem12LD/Z4Vp+jJnZEOhfkwIGvTZ4fNWXRutNicZFuU0uKDmKUuDw 1MceF9Inn35fJP/RecAvBO0Z3UpuZFEgDud8n14q7btRcOurXR5oCBNIv1DjCrbfyuFB TpPpEGTOWjd0q/G4KdCvlvUkxU38g190YEiT2dmXBNaCn2qDS1Q1cXZQQFn2vV2i4MHl KXySh/B8y9kwX8XfwB7HrF/NFnRuNpBlen/4U78u5ql0uJW4PmlGZV8KUbaBwakvg7KZ 93RQ==
MIME-Version: 1.0
X-Received: by 10.14.241.5 with SMTP id f5mr43817287eer.131.1373575646747; Thu, 11 Jul 2013 13:47:26 -0700 (PDT)
Received: by 10.14.175.135 with HTTP; Thu, 11 Jul 2013 13:47:26 -0700 (PDT)
In-Reply-To: <51DC92B1.7000908@gmail.com>
References: <51DC0F95.7010407@gmail.com> <hf8ot8hnpa93pi3t54c4d5qcc3p5tnb3ca@hive.bjoern.hoehrmann.de> <CAK3OfOgTNaLpRthrRcU4Bo+3z1aXUOOn0Ord7RBPN8z6TtiiWw@mail.gmail.com> <51DC7F87.6060503@gmail.com> <D3773B95-FF52-45D7-BE9F-2DEC92AFA67E@jorgechamorro.com> <51DC92B1.7000908@gmail.com>
Date: Thu, 11 Jul 2013 22:47:26 +0200
Message-ID: <CALcybBBF+=7RE3wqhZE6m=VzQ1HZK3GChoZd2xr_3x992521pg@mail.gmail.com>
From: Francis Galiegue <fgaliegue@gmail.com>
To: "Peter F. Patel-Schneider" <pfpschneider@gmail.com>
Content-Type: text/plain; charset="UTF-8"
Cc: Nico Williams <nico@cryptonector.com>, Jorge Chamorro <jorge@jorgechamorro.com>, Bjoern Hoehrmann <derhoermi@gmx.net>, json@ietf.org
Subject: Re: [Json] Limitations on number size?
X-BeenThere: json@ietf.org
X-Mailman-Version: 2.1.12
Precedence: list
List-Id: "JavaScript Object Notation \(JSON\) WG mailing list" <json.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/json>, <mailto:json-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/json>
List-Post: <mailto:json@ietf.org>
List-Help: <mailto:json-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/json>, <mailto:json-request@ietf.org?subject=subscribe>
X-List-Received-Date: Thu, 11 Jul 2013 20:47:28 -0000

On Wed, Jul 10, 2013 at 12:46 AM, Peter F. Patel-Schneider
<pfpschneider@gmail.com> wrote:
[...]
>
> But everything that I've read about JSON indicates that JSON is supposed to
> be used for (portably) interchanging data.  If all there is to JSON is the
> grammar then what's the point of JSON?
>

Some JSON parsers support {de,}serializing numbers of an arbitrary
precision and/or scale. Castrating these languages just so that they
limit their possible numeric representations is castrating the value
of JSON itself.

The number production grammar is perfect as it is, I see no reason to change it.

--
Francis Galiegue, fgaliegue@gmail.com
JSON Schema in Java: http://json-schema-validator.herokuapp.com