HP C A.06.05 Reference Manual

Data Types and Declarations
Declarators
Chapter 358
int (*x)[n]; // Error - x not ordinary identifier
int y[n]; // Error - y not ordinary identifier
};
}
A goto statement is not allowed to jump past any declarations of identifiers having a VM type.
A jump within the scope is permitted.
goto L1; // Error - going INTO scope of VM type
{
int a[n];
a[j] = 4;
L1:
a[j] = 3;
goto L2; // OK, going WITHIN scope of VM type
a[j] = 5;
L2:
a[j] = 6;
}
goto L2; // Error - going INTO scope of VM type
The size of an object having a VM type is determined and fixed at the point of the object's
declaration and cannot be altered.
The following example assumes size of (int) = 4,
int n = 10, vla[n];
n = 20;
printf(""%d", sizeof(vla); // prints 40, not 80
Function Declarators
If D is a declarator, and T is some combination of type specifiers and storage class specifiers
(such as int), then the declaration
T D (
parameter-type-list
)
or
T D (
[identifier-list]
)
declares D to be a function returning type T. A function can return any type of object except an
array or a function. However, functions can return pointers to functions or arrays.
If the function declarator uses the form with the
parameter-type-list
, it is said to be in
prototype form. The parameter type list specifies the types of, and may declare identifiers for,
the parameters of the function. If the list terminates with an ellipsis (,…), no information
about the number of types of the parameters after the comma is supplied. The special case of
void as the only item in the list specifies that the function has no parameters.