Address some compiler warnings.

- Add explicit casts from long to int.
- Comment out method argument names that are unused.
- Always initialize a boolean variable before it's read.
This commit is contained in:
Alex Szpakowski 2016-10-08 22:07:20 -03:00
parent 19bdf90eba
commit 49ad2b72a1
6 changed files with 9 additions and 9 deletions

View file

@ -235,9 +235,9 @@ int TPpContext::ReadToken(TokenStream *pTok, TPpToken *ppToken)
case PpAtomConstInt:
if (len > 0 && tokenText[0] == '0') {
if (len > 1 && (tokenText[1] == 'x' || tokenText[1] == 'X'))
ppToken->ival = strtol(ppToken->name, 0, 16);
ppToken->ival = (int)strtol(ppToken->name, 0, 16);
else
ppToken->ival = strtol(ppToken->name, 0, 8);
ppToken->ival = (int)strtol(ppToken->name, 0, 8);
} else
ppToken->ival = atoi(ppToken->name);
break;