Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Posting-Version: version B 2.10.2 9/18/84; site brl-tgr.ARPA
Path: utzoo!watmath!clyde!burl!ulysses!allegra!mit-eddie!godot!harvard!seismo!brl-tgr!gwyn
From: gwyn@brl-tgr.ARPA (Doug Gwyn )
Newsgroups: net.lang.c,net.lang.pascal
Subject: Re: PASCAL as a systems programming langugage
Message-ID: <7211@brl-tgr.ARPA>
Date: Fri, 11-Jan-85 03:55:46 EST
Article-I.D.: brl-tgr.7211
Posted: Fri Jan 11 03:55:46 1985
Date-Received: Sat, 12-Jan-85 07:42:59 EST
References: <282@harvard.ARPA>
Distribution: net
Organization: Ballistic Research Lab
Lines: 41
Xref: watmath net.lang.c:3826 net.lang.pascal:180

> ...  The current state of the UN*X kernel (ever looked at namei or ever
> wondered where all these unreferenced inodes come from) and the UN*X 
> utilities ("My sendmail has a bug!") seem to indicate that 'C' is not
> that easy to debug either.

This argument is totally bogus.  You can't prove anything about the
relative merit of two languages by pointing at bad examples of either.
(Not to imply that UNIX is all that bad.)  By the way, what
unreferenced inodes?  I never noticed that problem..

> Indeed, no pointer arithmetic. Using arrays and indices instead is a
> lot more portable ...

There is nothing unportable about C pointers that are used in accordance
with the language rules.  C's convenient pointers are one of its
significant advantages for implementing systems efficiently.

> PASCAL is written such that the compiler has a lot of freedom in
> optimising the code. 'C' code, on the other hand, is very hard to
> optimise, just because 'C' allows you to do funny things like get a
> pointer to any variable anywhere &c.

Yes, C was designed to provide that level of control.  Traditional
optimization is much less important when the language is that close
to the machine already.

> So what? Why does the whole world have to look like '&&' and '||'?
> Use 'IF' instead, it might even come out more readable.

Using multiple "if"s is definitely LESS readable and is why && and ||
were invented in the first place.

Using J&W Pascal as a systems implementation language is much like
using Small-C or some similar emasculated C subset.  Sure, one can
do it (with some amount of cheating), but C was deliberately designed
to facilitate systems implementation and it is pretty good at that.
There are several improvements one would like to see (many of them
are in C++), but following the Pascal model is not one of them.

I note with disgusted amusement that C is the only significant major
language that was not considered in the Ada project.