Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Info
titleGenerated Content

This page is automatically generated from the "Automated Detection" sections in the individual guidelines. Do not modify this page directly.

Version number:
v7.5.0

EXP31-CPP. Avoid side effects in assertions

C++ checkers

Rule

Checker

Guideline

FLP31-CPP. Do not call functions expecting real values with complex valuesARR01-CPP. Do not apply the sizeof operator to a pointer when taking the size of an arrayASSERT_SIDE_EFFECT

CHECKED_RETURN

EXP12

MEM52-CPP.

Do not ignore values returned by functions or methods
CTOR_DTOR_LEAKMEM33-CPP. Ensure that aborted constructors do not leak

Detect and handle memory allocation errors

DELETE_VOID

EXP39

EXP57-CPP. Do not cast or delete pointers to incomplete classes

DIVIDE_BY_ZEROINT33-CPP. Ensure that division and modulo operations do not result in divide-by-zero errors

EVALUATION_ORDER

EXP30

EXP50-CPP. Do not depend on the order of evaluation

between sequence points
INTEGER_OVERFLOWINT30-CPP. Ensure that unsigned integer operations do not wrap
INTEGER_OVERFLOWARR30-CPP. Guarantee that array and vector indices are within the valid range
LINKAGE_CONFLICTDCL36-CPP. Do not declare an identifier with conflicting linkage classifications
MISRA_CASTINT31-CPP. Ensure that integer conversions do not result in lost or misinterpreted data
MISRA_CASTFLP34-CPP. Ensure that floating point conversions are within range of the new type
MISSING_BREAKMSC18-CPP. Finish every set of statements associated with a case label with a break statement
NEGATIVE_RETURNSINT31-CPP. Ensure that integer conversions do not result in lost or misinterpreted data
NO_EFFECTMSC11-CPP. Incorporate diagnostic tests using assertions
RETURN_LOCALDCL30-CPP. Declare objects with appropriate storage durations
REVERSE_NEGATIVEINT31-CPP. Ensure that integer conversions do not result in lost or misinterpreted data
TAINTED_STATICINT32-CPP. Ensure that operations on signed integers do not result in overflow

for side effects

RETURN_LOCAL

EXP54-CPP. Do not access an object outside of its lifetime

TAINTED_STRING_WARNING

VOID

TAINTED_STRING_WARNING

FIO30-CPP. Exclude user input from format strings

UNUSED_VALUEMSC12-CPP. Detect and remove code that has no effect

USE_AFTER_FREE

MEM50

WRAPPER_ESCAPESTR33

-CPP. Do not access

invalid output of c_str() or data()

freed memory

>