C parsing : Significance of spaces

Steven Pemberton steven at mcvax.UUCP
Fri Apr 27 06:00:41 AEST 1984


> Any programmer worth their salt, never meets these problems due
> to their judicious use of spaces and parentheses!!!

Now this comment may have been meant as :-), and if so I'm sorry about this.

In the now legendary tale of the loss of a NASA flight because in FORTRAN
	DO 10 I=1,10
and	DO 10 I=1.10
look so similar and have such different effects, I blame FORTRAN and not the
programmer for the loss. Computers should serve people, not vice versa.
This is one of the reasons I feel so uneasy when using C; there are so many
potential pitfalls! When I program I want to think about the problem at
hand, and not whether I should type an extra space here or not. A piece of
code can look so harmless and yet be completely different to what you expect.

If some future NASA flight, or Cruise missile come to that, should fail
because its programmer had written
	rate= *a/*b /*some comment here*/;
I'm going to blame C, and not some poor fool who's been let down by a
programming language.

You sometimes see the remark "I like C because it lets me do what I want".
Now, I'm all for a programming language letting you do want you want,
but one of the reasons I don't particularly like C is because it just as
easily lets me do want I don't want.
My perfect programming language would do both.

Steven Pemberton, CWI, Amsterdam; steven at mcvax.

(On second thoughts, in the case of a Cruise missile going wrong, I'd blame
the programmer too, for being involved.)



More information about the Comp.lang.c mailing list