Tokenizer: Fixed warnings about unsigned / signed conversion

This commit is contained in:
Daniel Marjamäki 2010-08-31 21:04:17 +02:00
parent 8ff1e71b22
commit 688b2aefe9
1 changed files with 2 additions and 2 deletions

View File

@ -3403,7 +3403,7 @@ void Tokenizer::simplifySizeof()
{
Token tempTok(0);
tempTok.str("*");
sizeOfVar[varId] = MathLib::toString<long>(sizeOfType(&tempTok));
sizeOfVar[varId] = MathLib::toString<unsigned long>(sizeOfType(&tempTok));
}
else if (Token::Match(tok->tokAt(-1), "%type% %var% [ ] = %str% ;"))
@ -3547,7 +3547,7 @@ void Tokenizer::simplifySizeof()
if (Token::Match(tok->next(), "( * )"))
{
tok->str(MathLib::toString<long>(sizeOfType(tok->tokAt(2))));
tok->str(MathLib::toString<unsigned long>(sizeOfType(tok->tokAt(2))));
Token::eraseTokens(tok, tok->tokAt(4));
}