VAX C Doesn't care about prototypes.

Karl Heuer karl at haddock.ima.isc.com
Sat Jul 21 11:11:40 AEST 1990


In article <1990Jul20.184748.4362 at lotus.com> blambert at lotus.UUCP (Brian Lambert) writes:
>void x(B *b);
>    A a;
>    x(&a); /* does not generate a warning */

File a bug report.  The arguments are *not* assignment compatible.

"3.3.4 Conversions that involve pointers (other than as permitted by the
constraints of 3.3.16.1) shall be specified by means of an explicit cast."

I think this should have been under Constraints rather than Semantics; as it
stands, the diagnostic appears to be optional.  Is there any value in *not*
flagging this as an error?  (Btw, this same clause covers pointer-vs-int
collisions.)

Karl W. Z. Heuer (karl at kelp.ima.isc.com or ima!kelp!karl), The Walking Lint



More information about the Comp.lang.c mailing list