1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-04-23 14:42:11 +02:00

Added data parameter to statement has no effect checker

This commit is contained in:
Alena Laskavaia 2010-05-11 02:37:10 +00:00
parent 6882aa6e56
commit 823deee35f
2 changed files with 2 additions and 2 deletions

View file

@ -27,7 +27,7 @@
defaultSeverity="Warning"
description="Finds statements like 'a;' or '-a;' or 'a-b;' which do no seems to have any side effect therefore suspicious"
id="org.eclipse.cdt.codan.internal.checkers.StatementHasNoEffectProblem"
messagePattern="Statement has no effect"
messagePattern="Statement has no effect ''{0}''"
name="Statement has no effect"/>
</checker>

View file

@ -54,7 +54,7 @@ public class StatementHasNoEffectChecker extends AbstractIndexAstChecker {
if (stmt instanceof IASTExpressionStatement) {
if (hasNoEffect(((IASTExpressionStatement) stmt)
.getExpression())) {
reportProblem(ER_ID, stmt);
reportProblem(ER_ID, stmt, stmt.getRawSignature());
}
return PROCESS_SKIP;
}