Subject: [Ltru] Re: Case-insensitive rules (Was: I-D ACTION:draft-ietf-ltru-4646bis-01.txt)

From: "Doug Ewell" <[email-masked]>
Date: Wed, 13 Dec 2006 05:56:41 -0800

Stephane Bortzmeyer <bortzmeyer at nic dot fr> wrote:

> An ABNF production like:
>
> privateuse    = ("x"/"X") 1*("-" (1*8alphanum))
>
> is redundant. Since every ABNF string is case-INsensitive, it would be 
> enough to write:
>
> privateuse    = "x" 1*("-" (1*8alphanum))

At some point during the development of 4646, somebody argued that both 
cases needed to be specified.  This made the ABNF quite a bit more 
cumbersome to read -- and actually we are now inconsistent about casing, 
because the production for "irregular" is now an enumeration of the 
valid tags but only in their canonical casing style.  "EN-GB-OED" is 
also a valid irregular tag.

Can you find an RFC that states unequivocally that ABNF strings are 
case-insensitive?  That would allow us to defend simplifying the 
productions.

--
Doug Ewell  *  Fullerton, California, USA  *  RFC 4645  *  UTN #14
http://users.adelphia.net/~dewell/
http://www1.ietf.org/html.charters/ltru-charter.html
http://www.alvestrand.no/mailman/listinfo/ietf-languages 

_______________________________________________
Ltru mailing list
[email-masked]
https://www1.ietf.org/mailman/listinfo/ltru

---

From: John Cowan <[email-masked]>
Date: Wed, 13 Dec 2006 09:01:37 -0500

> case-insensitive?  That would allow us to defend simplifying the 

No problem.  RFC 2234, which defines ABNF for IETF purposes, says
in Section 2.3:

   ABNF permits specifying literal text string directly, enclosed in
   quotation-marks.  Hence:

        command     =  "command string"

   Literal text strings are interpreted as a concatenated set of
   printable characters.

        NOTE:     ABNF strings are case-insensitive and
                  the character set for these strings is us-ascii.

   Hence:

        rulename = "abc"

   and:

        rulename = "aBc"

   will match "abc", "Abc", "aBc", "abC", "ABc", "aBC", "AbC" and "ABC".

                To specify a rule which IS case SENSITIVE,
                   specify the characters individually.

   For example:

        rulename    =  %d97 %d98 %d99

   or

        rulename    =  %d97.98.99

   will match only the string which comprises only lowercased
   characters, abc.

-- 
John Cowan                                <[email-masked]>
Yakka foob mog.  Grug pubbawup zink wattoom gazork.  Chumble spuzz.
    -- Calvin, giving Newton's First Law "in his own words"

---

From: Stephane Bortzmeyer <[email-masked]>
Date: Wed, 13 Dec 2006 16:10:12 +0100

On Wed, Dec 13, 2006 at 05:56:41AM -0800,
 Doug Ewell <[email-masked]> wrote 
 a message of 27 lines which said:

> At some point during the development of 4646, somebody argued that
> both cases needed to be specified.

He was clearly wrong. (But I sympathetize, I made the same mistake at
the beginning.)

> case-insensitive?  

Besides the good reference given by John Cowan, I would like to add
that RFC which do want case-sensitivity have to use numeric
values. See for instance how RFC 4627 describes the string "false"
(lowercase only):

        false = %x66.61.6c.73.65   ; false

I may add that every ABNF implementation I know of treats strings in a
case-insensitive way (as required by the RFC).

---

From: "Doug Ewell" <[email-masked]>
Date: Wed, 13 Dec 2006 08:09:26 -0800

> He was clearly wrong. (But I sympathetize, I made the same mistake at 

I wonder if anyone can find the thread on this list, many months ago, 
where someone argued that we had to specify both cases explicitly.  Our 
original ABNF assumed case insensitivity.  I'd hate to go through the 
process all over again of changing it, changing it back, etc.

> that RFC which do want case-sensitivity have to use numeric values. 
> See for instance how RFC 4627 describes the string "false" (lowercase 
> only):
>

---

From: Addison Phillips <[email-masked]>
Date: Wed, 13 Dec 2006 08:27:47 -0800

Your point is well-taken. I note that our addition of the grandfathered 
list ignores the casing issue, relying on the ABNF rules to get things 
right. Note that this would also affect the "singleton" production, 
which could then become:

   singleton = "a"-"w" / "y"-"z" / "0"-"9"
   ; single alphanumerics; 'x' reserved for private-use

Although....

 > case-insensitive way (as required by the RFC).

I note that people seem to have an incredibly difficult time actually 
reading one RFC, not to mention understanding ANBF, so we'll probably 
have to SAY LOUDLY that ABNF is case-insensitive in our own document.

Addison

-- 
Addison Phillips
Globalization Architect -- Yahoo! Inc.

Internationalization is an architecture.
It is not a feature.

---

From: John Cowan <[email-masked]>
Date: Wed, 13 Dec 2006 11:58:42 -0500

> have to SAY LOUDLY that ABNF is case-insensitive in our own document.

+1

-- 
John Cowan   http://ccil.org/~cowan    [email-masked]
We want more school houses and less jails; more books and less arsenals;
more learning and less vice; more constant work and less crime; more
leisure and less greed; more justice and less revenge; in fact, more of
the opportunities to cultivate our better natures.  --Samuel Gompers

---

From: Addison Phillips <[email-masked]>
Date: Wed, 13 Dec 2006 12:07:20 -0800

It seems reasonable to change it, provided we give sufficient text 
explaining it. I have made the changes in the editor's copy, which I 
should have posted shortly (but not today).

Addison

---

From: Stephane Bortzmeyer <[email-masked]>
Date: Wed, 13 Dec 2006 21:12:08 +0100

On Wed, Dec 13, 2006 at 08:27:47AM -0800,
 Addison Phillips <[email-masked]> wrote 
 a message of 55 lines which said:

> Note that this would also affect the "singleton" production, which
> could then become:
> 

I agree with this change.

> we'll probably have to SAY LOUDLY that ABNF is case-insensitive in
> our own document.

OK

---

From: Stephane Bortzmeyer <[email-masked]>
Date: Thu, 14 Dec 2006 12:49:36 +0100

On Wed, Dec 13, 2006 at 08:09:26AM -0800,
 Doug Ewell <[email-masked]> wrote 
 a message of 31 lines which said:

> I wonder if anyone can find the thread on this list, many months
> ago, where someone argued that we had to specify both cases
> explicitly.

I do not find such arguing. I find a thread where it was already
clearly explained that ABNF strings are case-insensitive
(http://www1.ietf.org/mail-archive/web/ltru/current/msg04263.html). In
this thread, some people even said that RFC 4646's grammar is wrong,
because it is non-deterministic
(http://www1.ietf.org/mail-archive/web/ltru/current/msg04260.html).

---

From: Frank Ellermann <[email-masked]>
Date: Thu, 14 Dec 2006 18:09:40 +0100

> both cases needed to be specified.

Not in LTRU, maybe before (?)

> the production for "irregular" is now an enumeration of the valid tags
> but only in their canonical casing style.

That's fine, "en-GB-oed" matches also "en-gb-oed" and...

> "EN-GB-OED" is also a valid irregular tag.

...with Addison's proposal to add a note about this ABNF-feature 4646bis
can now finally eliminate one of "x" / "X".

Frank

---

From: Addison Phillips <[email-masked]>
Date: Thu, 14 Dec 2006 09:50:56 -0800

Done. I'll be posting draft-02 online as the editor's copy (*not* 
submitting it) in a little bit.

Addison