Don't use Scanf()

aglew at ccvaxa.UUCP aglew at ccvaxa.UUCP
Mon Mar 21 16:44:00 AEST 1988


>One real stupidity I've seen many, many times is the
>over-use of printf.  The printf functions have their uses,
>and they do their job quite well, but please know what these
>uses are!!

It would be nice if compilers could do a bit of processing,
determine that printf("string with no formats") can be transformed
into puts -- so that we can get on with the important job of solving
problems, and not have to play games remembering which I/O function
to use today (well, tcputs() is almost what I need, but its 
buffering conflicts with fooprintf() which is implicitly used
by the error printing routine used in module xyzzy).



More information about the Comp.lang.c mailing list