Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!seismo!rutgers!clyde!cbosgd!osu-eddie!paul From: paul@tut.cis.ohio-state.edu.cis.ohio-state.edu (Paul Placeway) Newsgroups: comp.unix.questions Subject: Re: Why does this shell program run under csh???? Message-ID: <3657@osu-eddie.UUCP> Date: Fri, 5-Jun-87 15:51:42 EDT Article-I.D.: osu-eddi.3657 Posted: Fri Jun 5 15:51:42 1987 Date-Received: Wed, 10-Jun-87 01:02:27 EDT References: <7710@brl-adm.ARPA> Sender: news@osu-eddie.UUCP Reply-To: paul@tut.cis.ohio-state.edu.cis.ohio-state.edu (Paul Placeway) Organization: The Ohio State University, CIS Dept. Lines: 40 In article <7710@brl-adm.ARPA> rbj@icst-cmr.arpa (Root Boy Jim) writes: ... >It would have been laughable to expect people to change all their >existing scripts just so some grad student from a western university >could distinguish input meant for his program rather than one written >by several PhD's at an eastern public utility research lab. So he did >the next best thing, and proclaimed that his program wouldn't run >anything unless the first character was an octothorp, and would defer >to his better educated predecessors' program instead. ... > (Root Boy) Jim Cottrell It seems to be that Jim is being fast and loose with the better education implies better programming paridigm here. Bourn shell works, and has fewer bugs than Csh does, but if you look at the sources, you will discover that the thing is written in a poor excuse for Algol, implemented with the C pre-processor. Also, memory is allocated by trying to access the new memory, then if a segmentation fault happens, allocate by moving the break forward and trying again. Pretty poor programming practice. Csh, on the other hand, will try to free random parts of memory, and expects the allocator to deal with it (actually, it bounds checks the things, but still...). Also poor. Csh, however, did inovate a number of usefull things such as aliases (now in Korn Shell) and job control (well, csh _uses_ job control, the BSD kernal implements it...) It just goes to show: anyone, PhD or not, can implement good ideas with bad code... 8-) -=- -- Paul Placeway Department of Computer and Information Science SNail: The Ohio State University 2036 Neil Ave. Columbus OH USA 43210-1277 ARPA: paul@ohio-state.{arpa,csnet} (soon): paul@tut.cis.ohio-state.edu UUCP: ...!cbosgd!osu-eddie!paul