Many people who criticize the C programming language, do not understand its goals. This is just quotations from the introduction part of the C99 Rationale. Having it in HTML instead of PDF is nicer for linking.
The 11 Principles
The design comittee for the C99 standard declared eleven principles to guide the process. Here is the list. The rationale contains more details.
- Existing code is important, existing implementations are not
- C code can be portable
- C code can be non-portable
- Avoid "quiet changes."
- A standard is a treaty between implementor and programmer.
- Keep the spirit of C.
- Support international programming.
- Codify existing practice to address evident deficiencies.
- Minimize incompatibilities with C90.
- Minimize incompatibilities with C++.
- Maintain conceptual simplicity.
Some of those points are so interesting that I want to quote more from the document.
Although it strove to give programmers the opportunity to write truly portable programs, the C89 Committee did not want to force programmers into writing portably, to preclude the use of C as a "high-level assembler": the ability to write machine-specific code is one of the strengths of C
The Spirit of C
There are many facets of the spirit of C, but the essence is a community sentiment of the underlying principles upon which the C language is based. Some of the facets of the spirit of C can be summarized in phrases like:
- Trust the programmer.
- Don’t prevent the programmer from doing what needs to be done.
- Keep the language small and simple.
- Provide only one way to do an operation.
- Make it fast, even if it is not guaranteed to be portable.
The last proverb needs a little explanation. The potential for efficient code generation is one of the most important strengths of C. To help ensure that no code explosion occurs for what appears to be a very simple operation, many operations are defined to be how the target machine’s hardware does it rather than by a general abstract rule. An example of this willingness to live with what the machine does can be seen in the rules that govern the widening of char objects for use in expressions: whether the values of char objects widen to signed or unsigned quantities typically depends on which byte operation is more efficient on the target machine
The Committee is content to let C++ be the big and ambitious language. While some features of C++ may well be embraced, it is not the Committee’s intention that C become C++.