[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

IGNORE, warnings, and &stuff

Since &-stuff in the lambda list is already treated as magic, I propose
adding a new lambda list keyword called &IGNORE.  Writing

	(lambda (x &ignore y &ignore z) ...)

should be equivalent to

	(lambda (x g0001 y g0002 z)
	  (declare (ignore g0001 g0002))

I agree that code is not acceptable if it generates compiler warnings,
because (a) it trains people to ignore compiler output, so they won't
notice when significant warnings appear in the middle of routine stuff, and
(b) people who port code to a new machine can't be expected to know which
warnings can safely be ignored, unless they read and analyze the entire

For the same reasons, we should be careful about allowing users to turn off
entire classes of warnings just to silence a paranoid compiler.  Instead.  I
think compilers should be required to provide a declaration for each class
of warnings to locally specify that the user knows he is doing X and
doesn't need a warning about X in this instance.  The IGNORE declaration is
a good example.