gcc: fixed some compiler warnings when using -Wsign-conversion
This commit is contained in:
parent
6346e1aa90
commit
7fb44d1995
|
@ -720,8 +720,8 @@ const char * CheckMemoryLeakInFunction::call_func(const Token *tok, std::list<co
|
||||||
if (numpar <= 0)
|
if (numpar <= 0)
|
||||||
return "callfunc";
|
return "callfunc";
|
||||||
|
|
||||||
int par = 1;
|
unsigned int par = 1;
|
||||||
int parlevel = 0;
|
unsigned int parlevel = 0;
|
||||||
|
|
||||||
const bool dot(tok->previous()->str() == ".");
|
const bool dot(tok->previous()->str() == ".");
|
||||||
|
|
||||||
|
|
|
@ -6807,11 +6807,13 @@ void Tokenizer::deleteTokens(Token *tok)
|
||||||
|
|
||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
|
|
||||||
const char *Tokenizer::getParameterName(const Token *ftok, int par)
|
const char *Tokenizer::getParameterName(const Token *ftok, unsigned int par)
|
||||||
{
|
{
|
||||||
int _par = 1;
|
unsigned int _par = 1;
|
||||||
for (; ftok; ftok = ftok->next())
|
for (; ftok; ftok = ftok->next())
|
||||||
{
|
{
|
||||||
|
if (ftok->str() == ")")
|
||||||
|
break;
|
||||||
if (ftok->str() == ",")
|
if (ftok->str() == ",")
|
||||||
++_par;
|
++_par;
|
||||||
if (par == _par && Token::Match(ftok, "%var% [,)]"))
|
if (par == _par && Token::Match(ftok, "%var% [,)]"))
|
||||||
|
|
|
@ -92,7 +92,7 @@ public:
|
||||||
bool simplifyTokenList();
|
bool simplifyTokenList();
|
||||||
|
|
||||||
static void deleteTokens(Token *tok);
|
static void deleteTokens(Token *tok);
|
||||||
static const char *getParameterName(const Token *ftok, int par);
|
static const char *getParameterName(const Token *ftok, unsigned int par);
|
||||||
|
|
||||||
std::string fileLine(const Token *tok) const;
|
std::string fileLine(const Token *tok) const;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue