[comp.lang.c] pointers to arrays and the '&' oper

vijay@bradley.UUCP (03/07/89)

/* Written 11:19 am  Feb 16, 1989 by gwyn@smoke.BRL.MIL in bradley:comp.lang.c */
In article <3927@ingr.com> crossgl@ingr.com (Gordon Cross) writes:
>Allright, the recent discussion regarding pointers to arrays in C reminds
>me of something that I consider to be a major deficiency of the language.

It is actually the fact that arrays are not first-class objects in C
that is the deficiency.  This cannot be fully remedied without
invalidating large amounts of existing correct code.

>Since I am allowed to declare something that has type "pointer to an array
>of...", then why am I not permitted to apply the '&' (address of) operator
>directly to an array??

In ANSI C, you are allowed to do so.

Many existing (PCC-based) compilers permit &array but ignore the &.
That is not the ANSI C behavior, though.  For maximal portability
you should avoid using &array for a few years.
/* End of text from bradley:comp.lang.c */