Show template instantiation and not definition location in template instantiation debug message.

This commit is contained in:
Simon Martin 2015-04-05 14:54:24 +02:00
parent a16ed8f0e7
commit 0f7f08644c
1 changed files with 2 additions and 2 deletions

View File

@ -1271,9 +1271,9 @@ bool TemplateSimplifier::simplifyTemplateInstantiations(
if (typeForNewName.empty() || typeParametersInDeclaration.size() != typesUsedInTemplateInstantiation.size()) {
if (_settings->debugwarnings && errorlogger) {
std::list<const Token *> callstack(1, tok);
std::list<const Token *> callstack(1, tok2);
errorlogger->reportErr(ErrorLogger::ErrorMessage(callstack, &tokenlist, Severity::debug, "debug",
"Failed to instantiate template. The checking continues anyway.", false));
"Failed to instantiate template \"" + name + "\". The checking continues anyway.", false));
}
if (typeForNewName.empty())
continue;