casts to (void)

Peter DaSilva peter at kitty.UUCP
Sat Aug 10 02:51:29 AEST 1985


> > That's a mediocre solution, it shouldn't be necessary lint should know the
> > set of standard functions which results needn't be used. It's not accept-
> > able to either put (void) in front of printf(), scanf(), ...etc. or make
> > defines like "#define Printf (void) printf".
> 
> And programs that do this don't recover from write errors, like when a
> filesystem runs out of space.  That's what lint *correctly* complains about.

OK. How about

	Printf(fmt,a,b,c,d,e,f,g,h,i,j,k,l) { assert(printf(fmt,...)!=FAIL); }



More information about the Comp.lang.c mailing list