Subject: Re: #1177 FWS -> *WSP (Re: Ticket status, February 20, 2006)

From: "Charles Lindsey" <[email-masked]>
Date: Thu, 2 Mar 2006 15:09:25 GMT

In <[email-masked]> Harald Tveit Alvestrand <[email-masked]> writes:

>--On mandag, februar 27, 2006 11:25:46 +0000 Charles Lindsey 
><[email-masked]> wrote:

>> In that case, please can we have a NOTE such as the following after the
>> 2nd bullet in 2.2:
>>
>>     NOTE: It would be hard to enforce this restriction generally in the
>>     syntax.  Nevertheless, the opportunity has been to do so in a few easy
>>     cases by the use of *FWS rather than [FWS].
>>

>I don't see the need for such a note. Harmless, but why?

To account for a different style than RFC 2822, and to make sure noone
goes looking for subtle effects of this different style (there are none,
of course).

>(in general, ABNF has to allow everything the text allows, but ABNF can't 
>possibly disallow everything the text disallows)

Indeed. But NOTEs are still useful "for the less than omniscient reader",
as Henry Spencer said, to explain things which may not be obvious at first
(or even second) sight.

-- 
Charles H. Lindsey ---------At Home, doing my own thing------------------------
Tel: +44 161 436 6131 Fax: +44 161 436 6133   Web: http://www.cs.man.ac.uk/~chl
Email: [email-masked]      Snail: 5 Clerewood Ave, CHEADLE, SK8 3JU, U.K.
PGP: 2C15F1A9      Fingerprint: 73 6D C2 51 93 A0 01 E7 65 E8 64 7E 14 A4 AB A5

---

From: Harald Alvestrand <[email-masked]>
Date: Fri, 03 Mar 2006 14:45:07 +0100

>goes looking for subtle effects of this different style (there are none,
That makes sense. In that case, the NOTE should say:

NOTE: The RFC 2822 specification uses <[WSP]> at the beginning of ABNF 
for header field content. This specification uses *WSP. This is done for 
consistency with the restriction described here, but the restriction 
applies to all header fields, not just those where ABNF is defined in 
this document.

Generally, a sentence containing the word "generally" should, as a 
general rule, be reworded :-)

---

From: "Charles Lindsey" <[email-masked]>
Date: Mon, 6 Mar 2006 12:00:34 GMT

>>>>    cases by the use of *FWS rather than [FWS].
.....

>applies to all header fields, not just those where ABNF is defined in 

No, that is not correct (RFC 2822 does not contain "[WSP]" anywhere, and
tends to use [CFWS] at the beginning _and_end_ of header field bodies,
except for <unstructured>, where it is of course [FWS]).

So what you would need to say is:

NOTE: The [RFC 2822] specification uses, directly or indirectly, [CFWS]
(occasionally [FWS]) at the beginning and end of the ABNF for header field
bodies. In contexts where <comment>s are disallowed, this specification
uses *WSP rather than [FWS]. This is done for consistency with the
restriction described above, but that restriction applies to all header
fields, not just those where *WSP is used in this document.

You might be able to prune that a little.