Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.1 6/24/83 (MC840302); site boring.UUCP Path: utzoo!watmath!clyde!burl!ulysses!allegra!mit-eddie!godot!harvard!seismo!mcvax!boring!guido From: guido@boring.UUCP Newsgroups: net.lang.c Subject: Re: Roff in C and iscntrl() Message-ID: <6274@boring.UUCP> Date: Fri, 4-Jan-85 12:41:26 EST Article-I.D.: boring.6274 Posted: Fri Jan 4 12:41:26 1985 Date-Received: Sun, 6-Jan-85 00:51:00 EST References: <1161@ut-ngp.UUCP> <6932@brl-tgr.ARPA> Reply-To: guido@boring.UUCP (Guido van Rossum) Organization: "Stamp Out BASIC" Committee, CWI, Amsterdam Lines: 18 Summary: Apparently-To: rnews@mcvax.LOCAL In article <6932@brl-tgr.ARPA> gwyn@brl-tgr.ARPA (Doug Gwyn) writes: >I wonder how ANYone could have decided that e.g. LF is NOT a control >character? (I'm sure the 4.2BSD fans will think that makes sense!) This was already in the original v7 ctype.h. It would not have been such a problem if they had documented it clearly (e.g. by putting the whole table in the manual page), but the manual page supplied with v7 was, alas, very vague about the actual assignments. I remember that the space was not considered a 'printing' character! (This has been fixed in all BSD versions I know of, at least, and I suppose also in sys3/sys5.) When one first checks for 'isspace' and only then for 'iscntrl', everything goes well. I guess the original idea was that 'isspace', 'iscntrl' and 'isprint' would designate disjunct sets, whose union whas the whole ASCII set (0-177 octal). Guido van Rossum, "Stamp Out BASIC" Committee, CWI, Amsterdam guido@mcvax.UUCP