Tokenizer: use static keyword instead of anonymous namespace for variables

This commit is contained in:
Daniel Marjamäki 2016-05-10 16:17:52 +02:00
parent 98626e5a46
commit f0fcb859c7
1 changed files with 7 additions and 8 deletions

View File

@ -2582,14 +2582,13 @@ static void setVarIdClassFunction(const std::string &classname,
}
}
namespace {
// Variable declarations can't start with "return" etc.
const std::set<std::string> notstart_c = make_container< std::set<std::string> > ()
<< "goto" << "NOT" << "return" << "sizeof"<< "typedef";
const std::set<std::string> notstart_cpp = make_container< std::set<std::string> > ()
<< notstart_c
<< "delete" << "friend" << "new" << "throw" << "using" << "virtual" << "explicit" << "const_cast" << "dynamic_cast" << "reinterpret_cast" << "static_cast" ;
}
// Variable declarations can't start with "return" etc.
static const std::set<std::string> notstart_c = make_container< std::set<std::string> > ()
<< "goto" << "NOT" << "return" << "sizeof"<< "typedef";
static const std::set<std::string> notstart_cpp = make_container< std::set<std::string> > ()
<< notstart_c
<< "delete" << "friend" << "new" << "throw" << "using" << "virtual" << "explicit" << "const_cast" << "dynamic_cast" << "reinterpret_cast" << "static_cast" ;
void Tokenizer::setVarId()
{