Re: [Json] Proposal for strings/Unicode text

Carsten Bormann <cabo@tzi.org> Mon, 17 June 2013 17:57 UTC

Return-Path: <cabo@tzi.org>
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 1355F21F93DA for <json@ietfa.amsl.com>; Mon, 17 Jun 2013 10:57:01 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -106.191
X-Spam-Level:
X-Spam-Status: No, score=-106.191 tagged_above=-999 required=5 tests=[AWL=0.058, BAYES_00=-2.599, HELO_EQ_DE=0.35, 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 E40u2ftFx9cr for <json@ietfa.amsl.com>; Mon, 17 Jun 2013 10:56:54 -0700 (PDT)
Received: from informatik.uni-bremen.de (mailhost.informatik.uni-bremen.de [IPv6:2001:638:708:30c9::12]) by ietfa.amsl.com (Postfix) with ESMTP id 8060721F93BA for <json@ietf.org>; Mon, 17 Jun 2013 10:56:51 -0700 (PDT)
X-Virus-Scanned: amavisd-new at informatik.uni-bremen.de
Received: from smtp-fb3.informatik.uni-bremen.de (smtp-fb3.informatik.uni-bremen.de [134.102.224.120]) by informatik.uni-bremen.de (8.14.4/8.14.4) with ESMTP id r5HHueck006375; Mon, 17 Jun 2013 19:56:40 +0200 (CEST)
Received: from [192.168.217.105] (p54893B55.dip0.t-ipconnect.de [84.137.59.85]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) by smtp-fb3.informatik.uni-bremen.de (Postfix) with ESMTPSA id 1693C3C61; Mon, 17 Jun 2013 19:56:40 +0200 (CEST)
Mime-Version: 1.0 (Mac OS X Mail 6.5 \(1508\))
Content-Type: text/plain; charset=iso-8859-1
From: Carsten Bormann <cabo@tzi.org>
In-Reply-To: <52755324-4C8D-452A-9A84-14691ACEEC7E@vpnc.org>
Date: Mon, 17 Jun 2013 19:56:38 +0200
Content-Transfer-Encoding: quoted-printable
Message-Id: <E69AED08-B07F-4D1B-9BEF-9A7B06454672@tzi.org>
References: <A723FC6ECC552A4D8C8249D9E07425A70FC52202@xmb-rcd-x10.cisco.com> <52755324-4C8D-452A-9A84-14691ACEEC7E@vpnc.org>
To: Paul Hoffman <paul.hoffman@vpnc.org>
X-Mailer: Apple Mail (2.1508)
Cc: "Joe Hildebrand \(jhildebr\)" <jhildebr@cisco.com>, json@ietf.org
Subject: Re: [Json] Proposal for strings/Unicode text
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: Mon, 17 Jun 2013 17:57:04 -0000

On Jun 17, 2013, at 19:27, Paul Hoffman <paul.hoffman@vpnc.org> wrote:

> What value is that comment?

Well, comments are always evil, because they mislead from the code.

> Doesn't it invite misinterpretation of the ABNF, which is exact?

The same argument could be made for

      begin-array     = ws %x5B ws  ; [ left square bracket

Actually, I'd argue for keeping in that style.

(And I know about U+27E6, U+301A, even U+FF3B.)

If we do want to explain, do it like this?

unescaped = ; any Unicode scalar value, except those that must be escaped:
          ; must escape C0 control characters %x0-1F
            %x20-21
          ; must escape %x22 " quotation mark
          / %x23-5B
          ; must escape %x5E \ reverse solidus
          / %x5D-D7FF
          ; not Unicode scalar values: %xD800-DFFF
          / %xE000-10FFFF

Grüße, Carsten