mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-06-09 02:36:01 +02:00
added comments
This commit is contained in:
parent
d02fb6433d
commit
86a922370c
1 changed files with 4 additions and 1 deletions
|
@ -63,7 +63,8 @@ public class StatementHasNoEffectChecker extends AbstractIndexAstChecker {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* We consider has not effect binary statements without assignment and
|
* We consider has not effect binary statements without assignment and
|
||||||
* unary statement which is not dec and inc
|
* unary statement which is not dec and inc. If operator is overloaded
|
||||||
|
* we not going to bother.
|
||||||
*
|
*
|
||||||
* @param e
|
* @param e
|
||||||
* @return
|
* @return
|
||||||
|
@ -74,6 +75,8 @@ public class StatementHasNoEffectChecker extends AbstractIndexAstChecker {
|
||||||
if (binExpr.getOperator() == IASTBinaryExpression.op_assign)
|
if (binExpr.getOperator() == IASTBinaryExpression.op_assign)
|
||||||
return false;
|
return false;
|
||||||
if (binExpr instanceof CPPASTBinaryExpression) {
|
if (binExpr instanceof CPPASTBinaryExpression) {
|
||||||
|
// unfortunately ICPPASTBinaryExpression does not have
|
||||||
|
// getOverload public method
|
||||||
CPPASTBinaryExpression cppBin = (CPPASTBinaryExpression) binExpr;
|
CPPASTBinaryExpression cppBin = (CPPASTBinaryExpression) binExpr;
|
||||||
ICPPFunction overload = cppBin.getOverload();
|
ICPPFunction overload = cppBin.getOverload();
|
||||||
if (overload != null)
|
if (overload != null)
|
||||||
|
|
Loading…
Add table
Reference in a new issue