Tokenizer::simplifyTemplates: Broke out handling for 'template<>..'
This commit is contained in:
parent
518a495334
commit
654116af61
|
@ -2548,7 +2548,7 @@ static void removeTemplates(Token *tok)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void Tokenizer::simplifyTemplates()
|
std::set<std::string> Tokenizer::simplifyTemplatesExpandSpecialized()
|
||||||
{
|
{
|
||||||
std::set<std::string> expandedtemplates;
|
std::set<std::string> expandedtemplates;
|
||||||
|
|
||||||
|
@ -2614,6 +2614,15 @@ void Tokenizer::simplifyTemplates()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
return expandedtemplates;
|
||||||
|
}
|
||||||
|
|
||||||
|
void Tokenizer::simplifyTemplates()
|
||||||
|
{
|
||||||
|
std::set<std::string> expandedtemplates;
|
||||||
|
|
||||||
|
expandedtemplates = simplifyTemplatesExpandSpecialized();
|
||||||
|
|
||||||
// Locate templates..
|
// Locate templates..
|
||||||
std::list<Token *> templates;
|
std::list<Token *> templates;
|
||||||
for (Token *tok = _tokens; tok; tok = tok->next())
|
for (Token *tok = _tokens; tok; tok = tok->next())
|
||||||
|
|
|
@ -25,6 +25,7 @@
|
||||||
#include <string>
|
#include <string>
|
||||||
#include <map>
|
#include <map>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
#include <set>
|
||||||
|
|
||||||
class Token;
|
class Token;
|
||||||
class ErrorLogger;
|
class ErrorLogger;
|
||||||
|
@ -395,6 +396,12 @@ public:
|
||||||
*/
|
*/
|
||||||
void simplifyTemplates();
|
void simplifyTemplates();
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Expand specialized templates : "template<>.."
|
||||||
|
* \return names of expanded templates
|
||||||
|
*/
|
||||||
|
std::set<std::string> simplifyTemplatesExpandSpecialized();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Used after simplifyTemplates to perform a little cleanup.
|
* Used after simplifyTemplates to perform a little cleanup.
|
||||||
* Sometimes the simplifyTemplates isn't fully successful and then
|
* Sometimes the simplifyTemplates isn't fully successful and then
|
||||||
|
|
Loading…
Reference in New Issue