From owner-freebsd-standards@FreeBSD.ORG Mon Aug 4 07:19:33 2003 Return-Path: Delivered-To: freebsd-standards@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4ECFF37B404; Mon, 4 Aug 2003 07:19:33 -0700 (PDT) Received: from whale.sunbay.crimea.ua (whale.sunbay.crimea.ua [212.110.138.65]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6423343F85; Mon, 4 Aug 2003 07:19:13 -0700 (PDT) (envelope-from ru@sunbay.com) Received: from whale.sunbay.crimea.ua (ru@localhost [127.0.0.1]) h74EIw0U064171 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Mon, 4 Aug 2003 17:18:58 +0300 (EEST) (envelope-from ru@sunbay.com) Received: (from ru@localhost) by whale.sunbay.crimea.ua (8.12.9/8.12.8/Submit) id h74EIwVR064166; Mon, 4 Aug 2003 17:18:58 +0300 (EEST) (envelope-from ru) Date: Mon, 4 Aug 2003 17:18:58 +0300 From: Ruslan Ermilov To: Andrey Chernov Message-ID: <20030804141858.GB60105@sunbay.com> References: <20030804195135.0562a9a2.yosimoto@waishi.jp> <20030804114723.GB39384@sunbay.com> <20030804223833.6c9a6718.yosimoto@waishi.jp> <20030804134636.GA39138@nagual.pp.ru> <20030804135713.GA39289@nagual.pp.ru> <20030804140332.GA39367@nagual.pp.ru> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="4bRzO86E/ozDv8r1" Content-Disposition: inline In-Reply-To: <20030804140332.GA39367@nagual.pp.ru> User-Agent: Mutt/1.5.4i cc: standards@freebsd.org cc: current@freebsd.org Subject: Re: buildworld broken after installworld X-BeenThere: freebsd-standards@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Standards compliance List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 04 Aug 2003 14:19:33 -0000 --4bRzO86E/ozDv8r1 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable [ standards@ Cc:ed ] On Mon, Aug 04, 2003 at 06:03:32PM +0400, Andrey Chernov wrote: > On Mon, Aug 04, 2003 at 17:57:13 +0400, Andrey Chernov wrote: >=20 > > > There is > > >=20 > > > tr '[a-z]' '[A-Z]' > > >=20 > > > which can be different for different locales since use collate now as > > > required by POSIX. Please tell which exact non-C locale you use and w= hat > > > happens? I miss start of this discussion. > >=20 > > Well, I found error in the archives, so the question remains, what loca= le=20 > > you use? >=20 > For example, this result is right and not the bug (but wrong tr usage): >=20 > env LANG=3Dde_DE.ISO8859-1 tr '[a-z]' '[A-Z]' > vi_zero > WI_]ERO >=20 Clearly this is a useless construct then. I can read this in the POSIX.1-2003 spec when it comes to tr(1): : c-c In the POSIX locale, this construct shall : represent the range of collating elements between : the range endpoints (as long as neither endpoint : is an octal sequence of the form \octal), : inclusive, as defined by the collation sequence. : The characters or collating elements in the : range shall be placed in the array in ascending : collation sequence. If the second endpoint : precedes the starting endpoint in the collation : sequence, it is unspecified whether the range : of collating elements is empty, or this construct : is treated as invalid. In locales other than ^^^^^^^^^^^^^^^^^^^^^ : the POSIX locale, this construct has unspecified ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ : behavior. ^^^^^^^^ This is identical to a similar issue with awk(1), and the latest snapshot of the One True AWK reverts to NOT using strcoll(3) to handle character ranges in RE, because different locales and even the same locales on different operating systems (FreeBSD, Linux, and Solaris were compared) have different ideas about the collating order. On Linux, the German locale's collating sequence will be ``A a ... B b'', while on FreeBSD, it's ``A B ... a b''. So I'd rather prefer if we revert to the old behavior in tr(1). Cheers, --=20 Ruslan Ermilov Sysadmin and DBA, ru@sunbay.com Sunbay Software Ltd, ru@FreeBSD.org FreeBSD committer --4bRzO86E/ozDv8r1 Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.1 (FreeBSD) iD8DBQE/LmtSUkv4P6juNwoRApBUAJ432W3ibErlWOQ/8iLbNY1BuWCLKQCffdbv fED2u9Hfcu0M/2dMAkgjXOU= =n8OG -----END PGP SIGNATURE----- --4bRzO86E/ozDv8r1--