Re: [apps-discuss] Review of: draft-yevstifeyev-abnf-separated-lists-02

Julian Reschke <julian.reschke@gmx.de> Tue, 14 December 2010 07:27 UTC

Return-Path: <julian.reschke@gmx.de>
X-Original-To: apps-discuss@core3.amsl.com
Delivered-To: apps-discuss@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 776613A6F6F for <apps-discuss@core3.amsl.com>; Mon, 13 Dec 2010 23:27:43 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -104.65
X-Spam-Level:
X-Spam-Status: No, score=-104.65 tagged_above=-999 required=5 tests=[AWL=-2.051, BAYES_00=-2.599, USER_IN_WHITELIST=-100]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id tm-7Qk9O5Gnd for <apps-discuss@core3.amsl.com>; Mon, 13 Dec 2010 23:27:42 -0800 (PST)
Received: from mail.gmx.net (mailout-de.gmx.net [213.165.64.23]) by core3.amsl.com (Postfix) with SMTP id DE6333A6EFB for <apps-discuss@ietf.org>; Mon, 13 Dec 2010 23:27:41 -0800 (PST)
Received: (qmail invoked by alias); 14 Dec 2010 07:29:19 -0000
Received: from p508FD842.dip.t-dialin.net (EHLO [192.168.178.33]) [80.143.216.66] by mail.gmx.net (mp005) with SMTP; 14 Dec 2010 08:29:19 +0100
X-Authenticated: #1915285
X-Provags-ID: V01U2FsdGVkX19GZ4BeOopG50DZK/GHHRaFjDJtGQYL8F8N6n9H3j 6uFrmAkqgsxyMd
Message-ID: <4D071CCB.5040509@gmx.de>
Date: Tue, 14 Dec 2010 08:29:15 +0100
From: Julian Reschke <julian.reschke@gmx.de>
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US; rv:1.9.2.13) Gecko/20101207 Lightning/1.0b2 Thunderbird/3.1.7
MIME-Version: 1.0
To: "Thomson, Martin" <Martin.Thomson@andrew.com>
References: <4D028FE0.20906@bbiw.net> <4D03A25E.9060709@dcrocker.net> <4D05EDB8.6090901@gmx.de> <8B0A9FCBB9832F43971E38010638454F03F34FAC7A@SISPE7MB1.commscope.com>
In-Reply-To: <8B0A9FCBB9832F43971E38010638454F03F34FAC7A@SISPE7MB1.commscope.com>
Content-Type: text/plain; charset="UTF-8"; format="flowed"
Content-Transfer-Encoding: 7bit
X-Y-GMX-Trusted: 0
Cc: Mykyta Yevstifeyev <evnikita2@gmail.com>, "dcrocker@bbiw.net" <dcrocker@bbiw.net>, "apps-discuss@ietf.org" <apps-discuss@ietf.org>
Subject: Re: [apps-discuss] Review of: draft-yevstifeyev-abnf-separated-lists-02
X-BeenThere: apps-discuss@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: General discussion of application-layer protocols <apps-discuss.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/apps-discuss>, <mailto:apps-discuss-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/apps-discuss>
List-Post: <mailto:apps-discuss@ietf.org>
List-Help: <mailto:apps-discuss-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/apps-discuss>, <mailto:apps-discuss-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 14 Dec 2010 07:27:43 -0000

On 13.12.2010 23:13, Thomson, Martin wrote:
> On 2010-12-13 at 20:56:08, Julian Reschke wrote:
>> "Wherever this construct is used, null elements are allowed, but do not
>> contribute to the count of elements present. That is, "(element), ,
>> (element) " is permitted, but counts as only two elements. Therefore,
>> where at least one element is required, at least one non-null element
>> MUST be present. Default values are 0 and infinity so that "#element"
>> allows any number, including zero; "1#element" requires at least one;
>> and "1#2element" allows one or two." --
>> <http://greenbytes.de/tech/webdav/rfc2616.html#rfc.section.2.1>
>
> For HTTP, the # rule can be handled with some tweaking...
>
>    a = #b
>
> ->
>
>    a = *LWS *^(*LWS "," *LWS)[b]
>
> It means that this isn't as directly usable by HTTP, though establishing a convention would make this a little easier.
>
>    a = *LWS *^COMMA[b]

Maybe I wasn't clear about the problem I see.

When in the HTTP grammar, we say

   1#2element

that matches the following header field values

   element

   element, element

   element, , element

So empty elements aren't counted.

I note that <http://tools.ietf.org/html/rfc822#section-2.7> has the same 
rule.

Is there a use case for this notation where empty list elements behave 
differently?

Best regards, Julian