How to parse this?
Sakari Jalovaara
sja at sirius.hut.fi
Sun Jan 20 05:16:05 AEST 1991
How about:
typedef char typename;
int f (int (typename []));
Is "f" compatible with
int f (int func (char arr[]));
or
int f (int arr[]);
?
3.5.4.3 has a rule on "a single typedef name in parenthesis." With
some imagination "typename[]" might be regarded as "a single typedef
name" (but how about "int g (int (* typename));" then -- would "* typename"
also be a single typedef name?)
I tried two compilers that claim to be standard-conforming and they
disagreed on this...
++sja
More information about the Comp.lang.c
mailing list