Re: [Json] {"Height": 125, "Width": "100"} example

"Martin J. Dürst" <duerst@it.aoyama.ac.jp> Thu, 10 October 2013 05:46 UTC

Return-Path: <duerst@it.aoyama.ac.jp>
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 4B84721F853A for <json@ietfa.amsl.com>; Wed, 9 Oct 2013 22:46:32 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -103.234
X-Spam-Level:
X-Spam-Status: No, score=-103.234 tagged_above=-999 required=5 tests=[AWL=0.556, BAYES_00=-2.599, HELO_EQ_JP=1.244, HOST_EQ_JP=1.265, MIME_8BIT_HEADER=0.3, RCVD_IN_DNSWL_MED=-4, USER_IN_WHITELIST=-100]
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 LsOIIV-VV+tJ for <json@ietfa.amsl.com>; Wed, 9 Oct 2013 22:46:26 -0700 (PDT)
Received: from scintmta02.scbb.aoyama.ac.jp (scintmta02.scbb.aoyama.ac.jp [133.2.253.34]) by ietfa.amsl.com (Postfix) with ESMTP id E54C621F8613 for <json@ietf.org>; Wed, 9 Oct 2013 22:46:19 -0700 (PDT)
Received: from scmse02.scbb.aoyama.ac.jp ([133.2.253.231]) by scintmta02.scbb.aoyama.ac.jp (secret/secret) with SMTP id r9A5kFL3021613; Thu, 10 Oct 2013 14:46:15 +0900
Received: from (unknown [133.2.206.134]) by scmse02.scbb.aoyama.ac.jp with smtp id 29c9_345e_47004322_316f_11e3_895c_001e6722eec2; Thu, 10 Oct 2013 14:46:14 +0900
Received: from [IPv6:::1] (unknown [133.2.210.1]) by itmail2.it.aoyama.ac.jp (Postfix) with ESMTP id B1276BFBBA; Thu, 10 Oct 2013 14:46:14 +0900 (JST)
Message-ID: <52563F18.5050408@it.aoyama.ac.jp>
Date: Thu, 10 Oct 2013 14:46:00 +0900
From: "\"Martin J. Dürst\"" <duerst@it.aoyama.ac.jp>
Organization: Aoyama Gakuin University
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US; rv:1.9.1.9) Gecko/20100722 Eudora/3.0.4
MIME-Version: 1.0
To: Tim Bray <tbray@textuality.com>
References: <255B9BB34FB7D647A506DC292726F6E11531CC024B@WSMSG3153V.srv.dir.telstra.com> <CAHBU6itKOO94etcQiVYrrjUZw0sKEx6k+sp8c1t5NaSbBUnDWw@mail.gmail.com>
In-Reply-To: <CAHBU6itKOO94etcQiVYrrjUZw0sKEx6k+sp8c1t5NaSbBUnDWw@mail.gmail.com>
Content-Type: text/plain; charset="UTF-8"; format="flowed"
Content-Transfer-Encoding: quoted-printable
Cc: "Manger, James H" <James.H.Manger@team.telstra.com>, "json@ietf.org" <json@ietf.org>
Subject: Re: [Json] {"Height": 125, "Width": "100"} example
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, 10 Oct 2013 05:46:32 -0000

On 2013/10/10 13:55, Tim Bray wrote:
> Don’t know if it’s a typo, but it’s kind of charmingly idiosyncratic and
> has lasted all these years... let’s spare it.

It's charmingly idiosyncratic (or should we call this idiosyntactic?) 
for those who have enough self-confidence to see what's going on.

Without explanation, it's not an example that should be copied in any 
way, so I strongly advocate fixing it one way or the other (i.e. 
removing the quotes from "100", changing "Width" to a property name more 
in line with a string value, adding an explanation, or some such).

Regards,   Martin.


> On Wed, Oct 9, 2013 at 6:03 PM, Manger, James H<
> James.H.Manger@team.telstra.com>  wrote:
>
>> 4627 and 4627bis include an example with the following object members:
>>    {
>>      "Height": 125,
>>      "Width":  "100"
>>    },
>>
>> This looks like a typo ("100" instead of 100), but it is still valid JSON.
>>
>> Is this a typo (that -bis should correct)?
>> Or is this a subtle suggestion to JSON parsers that they should
>> automatically
>> try to convert strings to numbers if an app asks for, say, the "Width"
>> field
>> as an int but the parser finds a string in the JSON?
>>
>> --
>> James Manger
>>
>>
>> _______________________________________________
>> json mailing list
>> json@ietf.org
>> https://www.ietf.org/mailman/listinfo/json
>>
>
>
>
> _______________________________________________
> json mailing list
> json@ietf.org
> https://www.ietf.org/mailman/listinfo/json