next up previous contents index
Next: Character testing functions Up: INTRODUCTION Previous: Function definitions

Array parameters

addAs vector and parallel hardware, and numeric applications in C, become more common, the aliasing semantics of C have been a source of frustration for implementors wanting to make optimum use of such hardware. If arrays are known not to overlap, certain optimizations become possible, but C currently provides no way to specify to a translator that argument arrays indeed do not overlap. The Committee, in adopting this future direction, hopes to provide common ground for implementors and users concerned with this problem, so that some future C Standard can adopt this non-overlapping rule on the basis of widespread experience.add

4 3 Character Handling<ctype.h> <ctype.h>

Pains were taken to eliminate any ASCII dependencies from the definition of the character handling functions. One notable result of this policy was the elimination of the function isascii, both because of the name and because its function was hard to generalize. Nevertheless, the character functions are often most clearly explained in concrete terms, so ASCII is used frequently to express examples.

Since these functions are often used primarily as macros, their domain is restricted to the small positive integers representable in an unsigned char, plus the value of EOF. EOF is traditionally -1, but may be any negative integer, and hence distinguishable from any valid character code. These macros may thus be efficiently implemented by using the argument as an index into a small array of attributes.

The Standard (.13.1) warns that names beginning with is and to, when these are followed by lower-case letters, are subject to future use in adding items to <ctype.h>.

4 3 1


Pete Jinks
Fri Jan 19 12:31:56 GMT 1996