A.8.8 Type names

In several contexts (to specify type conversions explicitly with a cast, to declare parameter types in function declarators, and as argument of sizeof) it is necessary to supply the name of a data type. This is accomplished using a type name, which is syntactically a declaration for an object of that type omitting the name of the object.

It is possible to identify uniquely the location in the abstract-declarator where the identifier would appear if the construction were a declarator in a declaration. The named type is then the same as the type of the hypothetical identifier. For example,

name respectively the types integer, pointer to integer, array of 3 pointers to integers, pointer to an unspecified number of integers, function of unspecified parameters returning pointer to integer, and array, of unspecified size, of pointers to functions with no parameters each returning an integer.

TCPL/A.08.08_Type_names (last edited 2008-02-23 15:34:54 by localhost)

ch3n2k.com | Copyright (c) 2004-2020 czk.