|C compiler warning messages? firstname.lastname@example.org (1997-04-06)|
|Re: C compiler warning messages? email@example.com (1997-04-07)|
|Proactive Compiler Error Messages firstname.lastname@example.org (Christopher Glaeser) (1997-04-08)|
|From:||Christopher Glaeser <email@example.com>|
|Date:||8 Apr 1997 09:36:39 -0400|
Recently, a programmer posted a common thread to a USENET news group
complaining about the code generated by the following:
count = count++;
He explained that his code worked *correctly* under an old compiler, and
does not work correctly using some new compiler; hence the new compiler
Of course, someone replies that his code has undefined behavior, to
which begins a back-and-forth of which compiler generates the *best*
code for this and other cases of undefined behavior. Various compilers
take an unfair bashing in these exchanges as compiler ABC is declared
better than compiler XYZ because the results for undefined behavior are
Perhaps compilers should fight back with proactive error messages to
thin the programming pool. Here are a few proposals.
ERROR: The compiler has detected undefined behavior in your program and
all source files have been deleted.
ERROR: Your programs have exceeded the maximum number of defects
permitted by this company. Notification has been sent to HR, and your
job is hereby terminated.
ERROR: You have written so many programs with undefined behavior since
you graduated that you obviously failed to grasp the concept.
Notification has been sent to your school of accreditation, and your
degree is hereby converted to agriculture.
With the growth in net-aware programming, the implementation details
should be fairly straightforward.
BTW, if you want to discuss these ideas further, I'll be in the fields
Christopher Glaeser firstname.lastname@example.org
Nullstone Corporation http://www.nullstone.com
Return to the
Search the comp.compilers archives again.