15-01-2008, 10:42 AM
Hi Frank,
Dead code is simply code that is executed, but which is not needed as it does not affect program output. For example:
Dead code (although not covered by this rule) indicates a possible error in the code. e.g. was the dead code above supposed to initialise some other object?
Dead code is simply code that is executed, but which is not needed as it does not affect program output. For example:
Code:
int32_t x
x = 12; // This is dead code, as the assigned value is never used.
x = 15;
use ( x );
Dead code (although not covered by this rule) indicates a possible error in the code. e.g. was the dead code above supposed to initialise some other object?