Tips from the compiler
bearophile
bearophileHUGS at lycos.com
Sun Oct 17 19:40:36 PDT 2010
In Bugzilla I have some compiler messages that don't fit in the set of error messages nor in the set of normal warnings. Like:
http://d.puremagic.com/issues/show_bug.cgi?id=5056
So I have proposed a third kind of compiler message, that are tips/suggestions to avoid possible bugs, improve the shape or performance of the code, and so on. The compiler shows those tips only on request.
My usage of C lints has shown me that such tips sometimes are very useful to avoid coding pitfalls, etc.
Here you may see some simple example of compiler tips from the CommonLips, that the compiler shows only when the higher optimization levels are used:
http://shootout.alioth.debian.org/u32/program.php?test=mandelbrot&lang=sbcl&id=1
Bye,
bearophile
More information about the Digitalmars-d
mailing list