Change Tokenizer member function name.
From 'simplifyQuestionMark' to 'simplifyConstTernaryOp' (the older name was not clear). Adjusted the doxy comment.
This commit is contained in:
parent
472a39d157
commit
c9e0089546
|
@ -3366,7 +3366,7 @@ bool Tokenizer::simplifyTokenList()
|
||||||
modified |= simplifyKnownVariables();
|
modified |= simplifyKnownVariables();
|
||||||
modified |= removeRedundantConditions();
|
modified |= removeRedundantConditions();
|
||||||
modified |= simplifyRedundantParenthesis();
|
modified |= simplifyRedundantParenthesis();
|
||||||
modified |= simplifyQuestionMark();
|
modified |= simplifyConstTernaryOp();
|
||||||
modified |= simplifyCalculations();
|
modified |= simplifyCalculations();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -4416,7 +4416,7 @@ bool Tokenizer::simplifyConditions()
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool Tokenizer::simplifyQuestionMark()
|
bool Tokenizer::simplifyConstTernaryOp()
|
||||||
{
|
{
|
||||||
bool ret = false;
|
bool ret = false;
|
||||||
for (Token *tok = list.front(); tok; tok = tok->next()) {
|
for (Token *tok = list.front(); tok; tok = tok->next()) {
|
||||||
|
|
|
@ -215,12 +215,12 @@ public:
|
||||||
void simplifyStdType();
|
void simplifyStdType();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Simplify question mark - colon operator
|
* Simplify easy constant '?:' operation
|
||||||
* Example: 0 ? (2/0) : 0 => 0
|
* Example: 0 ? (2/0) : 0 => 0
|
||||||
* @return true if something is modified
|
* @return true if something is modified
|
||||||
* false if nothing is done.
|
* false if nothing is done.
|
||||||
*/
|
*/
|
||||||
bool simplifyQuestionMark();
|
bool simplifyConstTernaryOp();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Simplify compound assignments
|
* Simplify compound assignments
|
||||||
|
|
Loading…
Reference in New Issue