From owner-freebsd-hackers Sun Sep 29 08:27:33 1996 Return-Path: owner-hackers Received: (from root@localhost) by freefall.freebsd.org (8.7.5/8.7.3) id IAA21470 for hackers-outgoing; Sun, 29 Sep 1996 08:27:33 -0700 (PDT) Received: from sequent.kiae.su (sequent.kiae.su [193.125.152.6]) by freefall.freebsd.org (8.7.5/8.7.3) with SMTP id IAA21434 for ; Sun, 29 Sep 1996 08:27:26 -0700 (PDT) Received: by sequent.kiae.su id AA15769 (5.65.kiae-2 ); Sun, 29 Sep 1996 19:25:08 +0400 Received: by sequent.KIAE.su (UUMAIL/2.0); Sun, 29 Sep 96 19:25:07 +0400 Received: (from ache@localhost) by nagual.ru (8.7.6/8.7.3) id TAA00468; Sun, 29 Sep 1996 19:05:59 +0300 (MSK) Message-Id: <199609291605.TAA00468@nagual.ru> Subject: Re: setlocale question In-Reply-To: <199609291255.OAA06956@uriah.heep.sax.de> from "J Wunsch" at "Sep 29, 96 02:55:11 pm" To: joerg_wunsch@uriah.heep.sax.de Date: Sun, 29 Sep 1996 19:05:58 +0300 (MSK) Cc: freebsd-hackers@freebsd.org, imp@village.org From: =?KOI8-R?Q?=E1=CE=C4=D2=C5=CA_=FE=C5=D2=CE=CF=D7?= (Andrey A. Chernov) Organization: self X-Class: Fast X-Mailer: ELM [version 2.4ME+ PL26 (25)] Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-hackers@freebsd.org X-Loop: FreeBSD.org Precedence: bulk > As [?KOI8-R?] wrote: > > > No, cat not require setlocale() (old variant, at least). > > It uses isascii() for -v which is locale-independend. > > It should use isprint(). Read the description of -v in the man page: > > -v Displays non-printing characters so they are visible. Control > ^^^^^^^^^^^^^^^^^^^^^^^ > > Since this will move it away from being ASCII-centric, it should > perhaps also use \xxx notation for non-printable characters instead of > this M-x crap. Alas, this would move us away from the other BSDs > again. Hmm. We already use locale for *vis() functions, propably it is time to implement it in cat too. I'll take care of it, if nobody disagree. IMHO, it will be better to preserve M-x notation to be compatible with *vis/*unvis functions and other BSDs. -- Andrey A. Chernov http://www.nagual.ru/~ache/