|Origins of == in C email@example.com (1995-07-20)|
|Re: Origins of == in C D.Chappell@biochem.usyd.edu.au (Doug CHAPPELL) (1995-07-25)|
|Re: Origins of == in C Brendan.Gowing@cs.tcd.ie (Brendan Gowing) (1995-07-26)|
|Re: Origins of == in C firstname.lastname@example.org (1995-07-28)|
|Re: Origins of == in C email@example.com (1995-07-31)|
|Re: Origins of == in C firstname.lastname@example.org (1995-08-01)|
|Re: Origins of == in C email@example.com (David Toland) (1995-08-03)|
|Re: Origins of == in C firstname.lastname@example.org (Bas V._de Bakker) (1995-08-09)|
|From:||email@example.com (Joachim Schrod)|
|Organization:||TH Darmstadt, FG Systemprogrammierung|
|Date:||Mon, 31 Jul 1995 10:59:16 GMT|
>, Brendan Gowing <Brendan.Gowing@cs.tcd.ie> writes:
> >The distinction between = and == in C has caused me no end of grief. ...
> >[My recollection is that they used = for assignment because it's a lot more
> >common than comparison. Besides, it's Fortran-compatible. -John]
> The moderator's comment is correct. As far as I can remember, someone
> somewhere along the line found that the number of assignments in a
> typical program far outweighed the number of equality checks. This was
> acknowledged by C's designers who reasoned that the single "=" for
> assignment would save key strokes over the more typical ":=".
In his article _Development of C_, Dennis Ritchie writes:
Other fiddles in the transition from BCPL to B were introduced AS
A MATTER OF TASTE [emphasis mine], and some remain controversial,
for example the decision to use the single character = for
assignment instead of :=.
It doesn't read as some transition that are really well planned.
PS: Cited from the HOPL-II preprint (SIGPLAN Notices, March 93), p.202.
Joachim Schrod Email: firstname.lastname@example.org
Computer Science Department
Technical University of Darmstadt, Germany
Return to the
Search the comp.compilers archives again.