Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!uunet!seismo!sundc!pitstop!sun!decwrl!labrea!Pescadero!mason From: mason@Pescadero.stanford.edu (Tony Mason) Newsgroups: comp.lang.c Subject: Re: MAJOR ANSI C FLAW (my opinion, of course) Message-ID: <11599@labrea.STANFORD.EDU> Date: Tue, 13-Oct-87 17:13:28 EDT Article-I.D.: labrea.11599 Posted: Tue Oct 13 17:13:28 1987 Date-Received: Thu, 15-Oct-87 20:35:42 EDT References: <1132@gilsys.UUCP> <1246@bsu-cs.UUCP> <6543@brl-smoke.ARPA> <104@aimt.UUCP> <8992@mimsy.UUCP> Sender: news@labrea.STANFORD.EDU Reply-To: mason@Pescadero.UUCP (Tony Mason) Organization: Stanford University Lines: 47 In article <8992@mimsy.UUCP> chris@mimsy.UUCP (Chris Torek) writes: >In article <104@aimt.UUCP> breck@aimt.UUCP (Robert Breckinridge Beatie) writes: >>Hmmm... why is a 6 character limit necessary in any environment? > >`If it was good enough for the 1950s, it is good enough for you' It wasn't so long ago that that limitation was very real. In Version 7 (not really the 50's) the limitation exists in the linker that a symbol name be no more than eight ascii characters. With one for the '\0' at the end, and one for the '_' at the beginning (remember this was a fix so variable names wouldn't clash with register names in the UNIX assembler.) All on the PDP. A machine wherein we have *space* optimizing compilers and programs still slowing down performance (remember the LEX presentation at USENIX last year?) The folks at Murray Hill decided it wasn't worth the effort to build a variable-length string handling system (and its associated complications.) Yet we now rail against them as we work on environments where we have demand- paged virtual memory machines, with 4MB of memory (or more, like my uVAX workstation with 16MB.) Why did the ANSI committee leave this temporary limitation in? My guess would be it had little to do with FORTRAN compilers but rather with machines that are still in use, still running UNIX programs, and still doing so in a limited address space. PDP's, for all their limitations, are still workhorses. If you don't want to write programs for those people still using PDP's, then you have a great chance of getting off with ignoring this restriction. Of the machines I work on, I cannot think of any besides a PDP that have this limitation (Sun doesn't, my VAX doesn't, my PC doesn't, MAC's don't, and Amiga's don't.) As for capitalization being meaningless, there are (gasp) systems which ignore case - another hold-over from bygone limitations imposed on programmers. In the MS-DOS world, the old linkers were case insensitive. Many older languages were also case insensitive (Pascal, for example.) How many people would have Pascal programs die if case sensitivity were suddenly forced upon them. For a vendor with a multi-language product selection, such a choice would be impossible to balance. Microsoft has taken a reasonable approach (use of a switch to turn on case sensitivity on MS-DOS machines.) To complain to the ANSI standards committee because they adopted (and in a rather limited fashion as was pointed out earlier) a standard allowing compatiblity with the *original* system on which C was developed seems a bit pedantic. I salute them for being able to balance the interests of so many people at all. Tony Mason Distributed Systems Group Stanford University mason@pescadero.stanford.edu