J
Joachim Schmitz
dropping the cast would produce at least 1 _additional_ diagnostic on yourKarl Heinze said:On Sun, 16 Sep 2007 12:29:17 +0200, "Peter J. Holzer"
Concerning...
Consider:
#include <stdio.h>
int main(void)
{
char *p = (char *) malloc(10);
return 0;
}
lcc-win32: "Missing prototype for 'malloc'.
Pelles C : "Missing prototype for 'malloc'".
gcc : "implicit declaration of function 'malloc'".
So at least the compilers *I* use issue useful warnings.
and at least 1 diagnostic _on every other_ compiler.
Usually the missing prototype is a warning (which you elect to can ignore)
and the type mismatch an error (which you can't ignore)