Renamed _codeWithTemplates
This commit is contained in:
parent
5dc29a9a16
commit
ef534c2d0d
|
@ -1735,12 +1735,12 @@ void TemplateSimplifier::simplifyTemplates(
|
||||||
ErrorLogger* errorlogger,
|
ErrorLogger* errorlogger,
|
||||||
const Settings *mSettings,
|
const Settings *mSettings,
|
||||||
const std::time_t maxtime,
|
const std::time_t maxtime,
|
||||||
bool &_codeWithTemplates
|
bool &codeWithTemplates
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
std::set<std::string> expandedtemplates(TemplateSimplifier::expandSpecialized(tokenlist.front()));
|
std::set<std::string> expandedtemplates(TemplateSimplifier::expandSpecialized(tokenlist.front()));
|
||||||
|
|
||||||
if (TemplateSimplifier::getTemplateDeclarations(tokenlist.front(), _codeWithTemplates).empty())
|
if (TemplateSimplifier::getTemplateDeclarations(tokenlist.front(), codeWithTemplates).empty())
|
||||||
return;
|
return;
|
||||||
|
|
||||||
// There are templates..
|
// There are templates..
|
||||||
|
@ -1757,7 +1757,7 @@ void TemplateSimplifier::simplifyTemplates(
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
std::list<TokenAndName> templateDeclarations(TemplateSimplifier::getTemplateDeclarations(tokenlist.front(), _codeWithTemplates));
|
std::list<TokenAndName> templateDeclarations(TemplateSimplifier::getTemplateDeclarations(tokenlist.front(), codeWithTemplates));
|
||||||
|
|
||||||
// Locate possible instantiations of templates..
|
// Locate possible instantiations of templates..
|
||||||
std::list<TokenAndName> templateInstantiations(TemplateSimplifier::getTemplateInstantiations(tokenlist.front(), templateDeclarations));
|
std::list<TokenAndName> templateInstantiations(TemplateSimplifier::getTemplateInstantiations(tokenlist.front(), templateDeclarations));
|
||||||
|
|
|
@ -204,14 +204,14 @@ public:
|
||||||
* @param errorlogger error logger
|
* @param errorlogger error logger
|
||||||
* @param mSettings settings
|
* @param mSettings settings
|
||||||
* @param maxtime time when the simplification should be stopped
|
* @param maxtime time when the simplification should be stopped
|
||||||
* @param _codeWithTemplates output parameter that is set if code contains templates
|
* @param codeWithTemplates output parameter that is set if code contains templates
|
||||||
*/
|
*/
|
||||||
static void simplifyTemplates(
|
static void simplifyTemplates(
|
||||||
TokenList& tokenlist,
|
TokenList& tokenlist,
|
||||||
ErrorLogger* errorlogger,
|
ErrorLogger* errorlogger,
|
||||||
const Settings *mSettings,
|
const Settings *mSettings,
|
||||||
const std::time_t maxtime,
|
const std::time_t maxtime,
|
||||||
bool &_codeWithTemplates);
|
bool &codeWithTemplates);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Simplify constant calculations such as "1+2" => "3"
|
* Simplify constant calculations such as "1+2" => "3"
|
||||||
|
|
|
@ -145,7 +145,7 @@ Tokenizer::Tokenizer() :
|
||||||
mSymbolDatabase(nullptr),
|
mSymbolDatabase(nullptr),
|
||||||
mVarId(0),
|
mVarId(0),
|
||||||
_unnamedCount(0),
|
_unnamedCount(0),
|
||||||
_codeWithTemplates(false), //is there any templates?
|
mCodeWithTemplates(false), //is there any templates?
|
||||||
_timerResults(nullptr)
|
_timerResults(nullptr)
|
||||||
#ifdef MAXTIME
|
#ifdef MAXTIME
|
||||||
,maxtime(std::time(0) + MAXTIME)
|
,maxtime(std::time(0) + MAXTIME)
|
||||||
|
@ -160,7 +160,7 @@ Tokenizer::Tokenizer(const Settings *settings, ErrorLogger *errorLogger) :
|
||||||
mSymbolDatabase(nullptr),
|
mSymbolDatabase(nullptr),
|
||||||
mVarId(0),
|
mVarId(0),
|
||||||
_unnamedCount(0),
|
_unnamedCount(0),
|
||||||
_codeWithTemplates(false), //is there any templates?
|
mCodeWithTemplates(false), //is there any templates?
|
||||||
_timerResults(nullptr)
|
_timerResults(nullptr)
|
||||||
#ifdef MAXTIME
|
#ifdef MAXTIME
|
||||||
,maxtime(std::time(0) + MAXTIME)
|
,maxtime(std::time(0) + MAXTIME)
|
||||||
|
@ -2299,7 +2299,7 @@ void Tokenizer::simplifyTemplates()
|
||||||
#else
|
#else
|
||||||
0, // ignored
|
0, // ignored
|
||||||
#endif
|
#endif
|
||||||
_codeWithTemplates);
|
mCodeWithTemplates);
|
||||||
}
|
}
|
||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
|
|
||||||
|
|
|
@ -764,7 +764,7 @@ public:
|
||||||
|
|
||||||
/** Was there templates in the code? */
|
/** Was there templates in the code? */
|
||||||
bool codeWithTemplates() const {
|
bool codeWithTemplates() const {
|
||||||
return _codeWithTemplates;
|
return mCodeWithTemplates;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -891,7 +891,7 @@ private:
|
||||||
* was there any templates? templates that are "unused" are
|
* was there any templates? templates that are "unused" are
|
||||||
* removed from the token list
|
* removed from the token list
|
||||||
*/
|
*/
|
||||||
bool _codeWithTemplates;
|
bool mCodeWithTemplates;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* TimerResults
|
* TimerResults
|
||||||
|
|
Loading…
Reference in New Issue