Open
Bug 1250096
Opened 10 years ago
Updated 3 years ago
Detect unused variables of some types with non-trivial constructor/destructor
Categories
(Developer Infrastructure :: Source Code Analysis, defect)
Developer Infrastructure
Source Code Analysis
Tracking
(Not tracked)
NEW
People
(Reporter: xidorn, Unassigned)
Details
Compilers warn unused variables, but not for those of type with non-trivial constructor or destructor.
But for some types, the constructor and destructor do not actually have side effect, and thus the corresponding variable is not useful if it is not used, e.g. the smart pointers.
We could probably add a new clang plugin attribute for those types, and raise error if they are defined but not used.
Updated•8 years ago
|
Product: Core → Firefox Build System
Comment 1•7 years ago
|
||
We have infrastructure for this for RefPtr; surely we could easily make it work for other types as well.
Updated•3 years ago
|
Product: Firefox Build System → Developer Infrastructure
Updated•3 years ago
|
Severity: normal → S3
You need to log in
before you can comment on or make changes to this bug.
Description
•