Type Names

Type names are used in some declarators in the following ways:

  • In explicit conversions

  • As arguments to the sizeof operator

  • As arguments to the new operator

  • In function prototypes

  • In typedef statements

A type name consists of type specifiers such as int or the name of a class or struct, in combination with an abstract declarator, as described in Declarations and Abstract Declarators. The abstract declarator has the effect of modifying the base type to produce a pointer, reference or array type. It is not required if specifying a scalar type.

In the following example, the arguments to the strcpy_s function are supplied using their type names. In the case of the strSource argument, const char is the type specifier and * is the abstract declarator:

errno_t strcpy_s( char *strDestination, size_t numberOfElements, const char *strSource );

See Also

Reference

Declarators