Difetti nel flusso di dati
Difetti relativi a errori di codifica nel flusso di dati, codice irraggiungibile, mancata inizializzazione, istruzioni di ritorno mancanti, scritture inutili
Questi difetti sono errori relativi al modo in cui le informazioni si muovono all'interno del codice. I difetti includono:
Codice morto o irraggiungibile
Codice non utilizzato
Informazioni non inizializzate
Risultati di Polyspace
Code deactivated by constant false condition | Code segment deactivated by #if 0 directive
or if(0) condition |
Dead code | Code does not execute |
Infinite loop | Loop termination condition might never be satisfied (Da R2023a) |
Missing return statement | Function with non-void return type does not return value on some
paths |
Non-initialized variable | Variable not initialized before use |
Non-initialized pointer | Pointer not initialized before dereference |
Partially accessed array | Array partly read or written before end of scope |
Pointer to non-initialized value converted to const pointer | Pointer to constant assigned address that does not contain a value |
Static uncalled function | Function with static scope not called in file |
Unreachable code | Code not executed because of preceding control-flow statements |
Useless if | Unnecessary if conditional |
Useless preprocessor conditional directive | Preprocessor conditional directive is always true or always false (Da R2022a) |
Variable shadowing | Variable hides another variable of same name with nested scope |
Write without a further read | Variable never read after assignment |
Argomenti
- Bug Finder Defect Groups
The Bug Finder defect checkers are classified into groups such as data flow, concurrency, numerical, and so on.