This text is a reference manual for the C programming language. OUf aim is to provide a complete and precise discussion of the language, the run-time libraries. and a style of C programming that emphasizes correctness, portability, and maintainability.
We expect our readers to already understand basic programming concepts, and many will be experienced C programmers. In keeping with a reference fannat, we present the language in a bottom-up order: lexical structure. preprocessor, deciarations, types, expressions, statements, functions, and run-time libraries. We have included many crossreferences in the text so that readers can begin at any point.
This Fifth Edition now includes a complete description of the latest international C standard, ISOIIEC 9899: 1999 (C99). I have been careful to indicate which features of the language and libraries are new in e99 and point out how e99 differs from the previous standard, e89. This is now the only book that serves as a reference for all the major versions of the C language: traditional C, the 1989 C Standard, the 1995 Amendment and Corrigenda to C89, and now the 1999 C Standard. It also covers the Clean C subset of Standard C and Standard C++. Although there is much new material in e99, I have not changed the chapter and section organization of the book significantly, so readers familiar with previous editions will not have problems finding the information they need.
This book originally grew out of our work at Tartan, Inc. developing a family of C compilers for a range of computers-from micros to mainframes. We wanted the compilers to be well documented, provide precise and helpful error diagnostics, and generate exceptionally efficient object code. A C program that compiles correctly with one compiler must compile correctly under all the others insofar as the hardware differences allow.
In 1984. despite C's popularity. we found that there was no description of C precise enough to guide us in designing the new compilers. Similarly, no existing description was precise enough for our programmer/customers, who would be using compilers that analyzed C programs more thoroughly than was the custom at that time. In this text, we have been especially sensitive to language features that affect program clarity, object code efficiency. and the portability of programs among different environments.