When is a cast not a cast?

Doug Gwyn gwyn at smoke.BRL.MIL
Fri May 26 02:28:24 AEST 1989


In article <6200006 at ux1.cso.uiuc.edu> phil at ux1.cso.uiuc.edu writes:
>What about:
>    q = NULL[i];  /* or even i[NULL] */
>    q = q[1];

Please don't do these things even if your particular compiler happens
to let you get away with it.  There is no reason to expect these to
work and on many C implementations they will fail.  There are other,
portable ways to accomplish such operations.



More information about the Comp.lang.c mailing list