ietf-822
[Top] [All Lists]

Re: Comma-seperated lists

2008-01-25 08:14:19



Pete Resnick wrote:
RFC 2822 not withstanding, were the following ever legal instantiations of <#element>?

, element ,
element, element,
, , ,

822 is not clear on this point to me, but it seems like those might be allowed. My obs- lists currently don't allow them. Thoughts?



1.  Empty List

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  ele-
     ment  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.

I read the above as at least implying that an empty list that nonetheless contains commas is allowed.


2.  White Space Around Commas

3.4.2.  WHITE SPACE

        Note:  In structured field bodies, multiple linear space ASCII
               characters  (namely  HTABs  and  SPACEs) are treated as
single spaces and may freely surround any symbol.

and

     specials    =  "(" / ")" / "<" / ">" / "@"  ; Must be in quoted-
                 /  "," / ";" / ":" / "\" / <">  ;  string, to use
                 /  "." / "[" / "]"              ;  within a word.

I read this combination as rather explicitly allowing white space around a 
comma.


I'll note that all of this matches what I would have expected -- and even wished that 822 had been more clear about.

The goal with the lexical model and rule for white space was to allow its use to be extremely free. If there was anywhere it might get used, without the ability to do parsing, the goal was to permit it.

d/
--

  Dave Crocker
  Brandenburg InternetWorking
  bbiw.net

<Prev in Thread] Current Thread [Next in Thread>