Tokenizer: comments/refactorings
This commit is contained in:
parent
4d1aae5859
commit
de75bdfed5
|
@ -2791,8 +2791,8 @@ void Tokenizer::simplifyTemplatesUseDefaultArgumentValues(const std::list<Token
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void Tokenizer::simplifyTemplatesInstantiate(std::list<Token *> &used,
|
void Tokenizer::simplifyTemplatesInstantiate(const Token *tok,
|
||||||
const Token *tok,
|
std::list<Token *> &used,
|
||||||
std::set<std::string> &expandedtemplates)
|
std::set<std::string> &expandedtemplates)
|
||||||
{
|
{
|
||||||
// this variable is not used at the moment. the intention was to
|
// this variable is not used at the moment. the intention was to
|
||||||
|
@ -3157,9 +3157,9 @@ void Tokenizer::simplifyTemplates()
|
||||||
//while (!done)
|
//while (!done)
|
||||||
{
|
{
|
||||||
done = true;
|
done = true;
|
||||||
for (std::list<Token *>::iterator iter1 = templates.begin(); iter1 != templates.end(); ++iter1)
|
for (std::list<Token *>::const_iterator iter1 = templates.begin(); iter1 != templates.end(); ++iter1)
|
||||||
{
|
{
|
||||||
simplifyTemplatesInstantiate(used, *iter1, expandedtemplates);
|
simplifyTemplatesInstantiate(*iter1, used, expandedtemplates);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -425,9 +425,13 @@ public:
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Simplify templates : expand all instantiatiations for a template
|
* Simplify templates : expand all instantiatiations for a template
|
||||||
|
* @todo It seems that inner templates should be instantiated recursively
|
||||||
|
* @param tok token where the template declaration begins
|
||||||
|
* @param used a list of template usages (not necessarily just for this template)
|
||||||
|
* @param expandedtemplates all templates that has been expanded so far. The full names are stored.
|
||||||
*/
|
*/
|
||||||
void simplifyTemplatesInstantiate(std::list<Token *> &used,
|
void simplifyTemplatesInstantiate(const Token *tok,
|
||||||
const Token *tok,
|
std::list<Token *> &used,
|
||||||
std::set<std::string> &expandedtemplates);
|
std::set<std::string> &expandedtemplates);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in New Issue