What every C Programmer should know about undefined behavior
What every C Programmer should know about undefined behavior
Posted May 16, 2011 18:28 UTC (Mon) by iabervon (subscriber, #722)In reply to: What every C Programmer should know about undefined behavior by cfischer
Parent article: What every C Programmer should know about undefined behavior #2/3
Of course, there's also the situation of a programmer who doesn't think C99 has caught on modifying a C99 codebase, and moving the line with the declaration up to the start of the block; the result may not be "natural" C89 to write, but it might be a "natural" C89 change to a "natural" C99 block.
Posted May 16, 2011 19:57 UTC (Mon)
by jreiser (subscriber, #11027)
[Link]
Often it is better to make a block by inserting the braces which enclose the intended scope.
If you then have to write C89, the easy thing is to move the whole line, ...
What every C Programmer should know about undefined behavior