Refactoring. Use "str" instead of "aaaa0"
This commit is contained in:
parent
774ca2c350
commit
f63f223976
|
@ -132,7 +132,7 @@ const TOKEN * CheckClass::FindClassFunction( const TOKEN *tok, const char classn
|
||||||
indentlevel = 1;
|
indentlevel = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( tok->aaaa0() == '{' )
|
if ( tok->str() == "{" )
|
||||||
{
|
{
|
||||||
// If indentlevel==0 don't go to indentlevel 1. Skip the block.
|
// If indentlevel==0 don't go to indentlevel 1. Skip the block.
|
||||||
if ( indentlevel > 0 )
|
if ( indentlevel > 0 )
|
||||||
|
@ -142,9 +142,9 @@ const TOKEN * CheckClass::FindClassFunction( const TOKEN *tok, const char classn
|
||||||
{
|
{
|
||||||
for ( ; tok; tok = tok->next )
|
for ( ; tok; tok = tok->next )
|
||||||
{
|
{
|
||||||
if ( tok->aaaa0() == '{' )
|
if ( tok->str() == "{" )
|
||||||
++indentlevel;
|
++indentlevel;
|
||||||
else if ( tok->aaaa0() == '}' )
|
else if ( tok->str() == "}" )
|
||||||
{
|
{
|
||||||
--indentlevel;
|
--indentlevel;
|
||||||
if ( indentlevel <= 0 )
|
if ( indentlevel <= 0 )
|
||||||
|
@ -158,7 +158,7 @@ const TOKEN * CheckClass::FindClassFunction( const TOKEN *tok, const char classn
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( tok->aaaa0() == '}' )
|
if ( tok->str() == "}" )
|
||||||
{
|
{
|
||||||
indentlevel--;
|
indentlevel--;
|
||||||
if ( indentlevel < 0 )
|
if ( indentlevel < 0 )
|
||||||
|
@ -171,9 +171,9 @@ const TOKEN * CheckClass::FindClassFunction( const TOKEN *tok, const char classn
|
||||||
if ( TOKEN::Match( tok, "%var1% (", _funcname ) )
|
if ( TOKEN::Match( tok, "%var1% (", _funcname ) )
|
||||||
{
|
{
|
||||||
const TOKEN *tok2 = tok;
|
const TOKEN *tok2 = tok;
|
||||||
while ( tok2 && tok2->aaaa0() != '{' && tok2->aaaa0() != ';' )
|
while ( tok2 && tok2->str() != "{" && tok2->str() != ";" )
|
||||||
tok2 = tok2->next;
|
tok2 = tok2->next;
|
||||||
if ( tok2 && tok2->aaaa0() == '{' )
|
if ( tok2 && tok2->str() == "{" )
|
||||||
return tok;
|
return tok;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue