From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 11214 invoked from network); 8 Jul 1998 11:21:23 -0000 Received: from math.gatech.edu (list@130.207.146.50) by ns1.primenet.com.au with SMTP; 8 Jul 1998 11:21:23 -0000 Received: (from list@localhost) by math.gatech.edu (8.8.5/8.8.5) id HAA16005; Wed, 8 Jul 1998 07:01:05 -0400 (EDT) Resent-Date: Wed, 8 Jul 1998 07:01:05 -0400 (EDT) From: "Bart Schaefer" Message-Id: <980708040212.ZM8132@candle.brasslantern.com> Date: Wed, 8 Jul 1998 04:02:12 -0700 In-Reply-To: <199807080640.BAA01227@hzoli.home> Comments: In reply to Zoltan Hidvegi "Re: 'LC_COLLATE=de ls [A-Z]*' expands to 'every file' including lowercase" (Jul 8, 1:40am) References: <199807080640.BAA01227@hzoli.home> X-Mailer: Z-Mail (4.0b.820 20aug96) To: Zoltan Hidvegi , zsh-workers@math.gatech.edu (Zsh hacking and development) Subject: Re: 'LC_COLLATE=de ls [A-Z]*' expands to 'every file' including lowercase MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Resent-Message-ID: <"cUuw02.0.zv3.m5rer"@math> Resent-From: zsh-workers@math.gatech.edu X-Mailing-List: archive/latest/4208 X-Loop: zsh-workers@math.gatech.edu Precedence: list Resent-Sender: zsh-workers-request@math.gatech.edu On Jul 8, 1:40am, Zoltan Hidvegi wrote: } Subject: Re: 'LC_COLLATE=de ls [A-Z]*' expands to 'every file' including l } } > I'd vote in favor of removing HAVE_STRCOLL from matchonce() in glob.c. } } According to the standard: } } LC_COLLATE } This variable determines the behaviour of range expressions, } equivalence classes and multi-character collating elements } within pattern matching. Which standard, specifically? This is a case where that standard is harmfully flying in the face of common sense. Of course LC_COLLATE ought to apply to POSIX character classes once those are supported, and ought to apply to the collation of any resulting ordered list. But to have it apply to the characters within ranges like [A-Z] will cause the simplest shell scripts to go completely haywire; we'll have to start putting "local LC_COLLATE=C" or some such at the top of every autoloaded function, along with all the "emulate -R" and "setopt localoptions" junk that's already there. Standards are not meant to be followed blindly. That's why the IETF, for example, has a collection of rules for interpreting MUST, SHOULD, MAY, etc. when they appear in IETF documents. -- Bart Schaefer Brass Lantern Enterprises http://www.well.com/user/barts http://www.brasslantern.com