Unused Definition

Definition:

  • Unused code should be removed. Note that only local definitions can be removed safely because they cannot be accessed from outside the defining unit. For global definitions there might exist references in modules which have not been considered.

Code Example:

function unused_f ( in integer i ) return integer {
  var integer j := 4 2 , k ;
  return i + j ;
}

References:

Quality attributes

  • - Code Example

  • - Cause and Effect

  • - Frequency

  • - Refactoring