value flow: use const when possible

This commit is contained in:
Daniel Marjamäki 2014-01-24 06:16:23 +01:00
parent de20ba6763
commit 135998abba
1 changed files with 1 additions and 1 deletions

View File

@ -446,7 +446,7 @@ static void valueFlowAfterAssign(TokenList *tokenlist, ErrorLogger *errorLogger,
// Lhs should be a variable
if (!tok->astOperand1() || !tok->astOperand1()->isName())
continue;
unsigned int varid = tok->astOperand1()->varId();
const unsigned int varid = tok->astOperand1()->varId();
if (varid == 0U)
continue;
const Variable *var = tok->astOperand1()->variable();