From comp.std.c Sun Jun 28 02:27:00 1992
From: firstname.lastname@example.org (Dennis Ritchie)
Subject: Re: Diff between Draft Proposed ANSI C and ANSI C K&R Books
Date: 27 Jun 92 06:18:43 GMT
Organization: AT&T Bell Laboratories, Murray Hill NJ
Here is a newer version of the errata list than the one that
was reposted. It's not really new (mod date of the file is
Jan 91) and not much different, but does note the
blemish. It's missing Henry
The C Programming Language, 2nd Edition
As the C standard wended its way through the approval
process and became final, Brian
and I prepared fixes to put
in new printings of the second edition of ``The C
Programming Language.'' These printings are identified by a
large red ``ANSI C'' in the upper right quadrant.
Fortunately, the changes are minor; some repair our bugs, a
few account for last-minute changes in the draft standard.
For the benefit of previous and near-future purchasers, here
are the changes that were made:
Two or three sentences in the Preface and Introduction are
updated to describe the state of the Standard.
atof is in
<math.h>; this changes 71, 76, 82, 121.
On page 86, error corrected: elided initializers are
for automatic as well as static variables.
On page 168: changed
1.0 to avoid potential overflow.
Minor typos are corrected on pages 87, 89, 164, 165, 168,
The inconspicuous references to
noalias on pages 192 and
211 are removed.
The following paragraph is added to the end of section A6.6
A pointer may be converted to another pointer whose
type is the same except for the addition or removal of
qualifiers (A4.4, A8.2) of the object type to which the
pointer refers. If qualifiers are added, the new
pointer is equivalent to the old except for
restrictions implied by the new qualifiers. If
qualifiers are removed, operations on the underlying
object remain subject to the qualifiers in its actual
On p. 199, beginning of section A6.8, ``Any pointer may be
converted to type
void *...'' is changed to ``Any pointer
>to an object< may be converted to type
On p. 204, A7.4.4, ``The operand of the unary
must have arithmetic or pointer type...'' should read ``must
have arithmetic type...''.
On p. 206, A7.9, about relational operators: ``Pointers to
objects of the same type may be compared...'' is changed to
``Pointers to object of the same type >(ignoring any
qualifiers)< may be compared...''.
The indented material on p. 209, ``According to the
restrictions... relaxing it.'' is removed. [This is
related to the paragraph added above. The wording of the
penultimate draft made it useless to take an
pointer, cast it to
(const int *), then cast it back to
On p. 219 middle, initialization of structures, add
``Unnamed bit-field members are ignored, and are not
Appendix B changes:
Appendix C change:
p 242: Add ``
fflush(NULL) flushes all output streams.'' to
p 243: Change to ``it must be called before reading,
writing >or any other operation<'' in
p 249: Add ``Comparison functions treat arguments as
unsigned char arrays.'' to
p 255: Change range of
tm_sec to (0,61) for leap seconds.
p 255: Change
p 257: Drop
L suffixes from
tm_sec range is (00,61) here too.
The index has been reprinted to fix a couple of typos and
account for motion within Appendix A; one page of the table
of contents is changed.
p 261: Change ``External declarations without any
specifiers...'' to ``External >data< declarations without
- Minor changes on page 131 to add & to last
- on page 208 to change ``equal'' to ``unequal'' in
the description of logical OR,
- and on page 254 to clarify
that only volatile automatics are saved with
Not yet fixed in any printing:
page 53: Note under the table should say
& as well as
+ - *
has higher precedence as a unary operator.
page 111: indent is too large, and a bit of program text is
page 231 extra right paren in nested call to
page 246: first argument of
sscanf should have type
const char *.
page 249: in description of
t => ct.