We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see ourdocumentation.
There was an error while loading.Please reload this page.
1 parentd5dacfd commit0e9fc04Copy full SHA for 0e9fc04
cpp/autosar/src/rules/M0-1-3/UnusedLocalVariable.ql
@@ -26,14 +26,8 @@ import codingstandards.cpp.deadcode.UnusedVariables
26
//
27
// For performance reasons, these special values should be collected in a single pass.
28
predicateexcludedConstantValue(stringvalue){
29
-// For constexpr variables used as template arguments, we don't see accesses (just the
30
-// appropriate literals). We therefore take a conservative approach and count the number of
31
-// template instantiations that use the given constant, and consider each one to be a use
32
-// of the variable
33
value=any(ClassTemplateInstantiationcti).getTemplateArgument(_).(Expr).getValue()
34
or
35
-// For static asserts too, check if there is a child which has the same value
36
-// as the constexpr variable.
37
value=any(StaticAssertsa).getCondition().getAChild*().getValue()
38
}
39