diff --git a/src/libs/3rdparty/cplusplus/Control.cpp b/src/libs/3rdparty/cplusplus/Control.cpp index ff966ee3320..4033b160283 100644 --- a/src/libs/3rdparty/cplusplus/Control.cpp +++ b/src/libs/3rdparty/cplusplus/Control.cpp @@ -821,11 +821,6 @@ bool Control::hasSymbol(Symbol *symbol) const return std::find(d->symbols.begin(), d->symbols.end(), symbol) != d->symbols.end(); } -void Control::squeeze() -{ - d->numericLiterals.reset(); -} - TopLevelDeclarationProcessor *Control::topLevelDeclarationProcessor() const { return d->processor; diff --git a/src/libs/3rdparty/cplusplus/Control.h b/src/libs/3rdparty/cplusplus/Control.h index 5556c41fddc..59b3cf4ad92 100644 --- a/src/libs/3rdparty/cplusplus/Control.h +++ b/src/libs/3rdparty/cplusplus/Control.h @@ -217,8 +217,6 @@ public: bool hasSymbol(Symbol *symbol) const; void addSymbol(Symbol *symbol); - void squeeze(); - private: class Data; friend class Data; diff --git a/src/libs/cplusplus/CppDocument.cpp b/src/libs/cplusplus/CppDocument.cpp index a0d0ef83621..5b55d09c198 100644 --- a/src/libs/cplusplus/CppDocument.cpp +++ b/src/libs/cplusplus/CppDocument.cpp @@ -711,8 +711,6 @@ void Document::releaseSourceAndAST() if (!_keepSourceAndASTCount.deref()) { _source.clear(); _translationUnit->release(); - if (_control) - _control->squeeze(); } } diff --git a/src/libs/cplusplus/NamePrettyPrinter.cpp b/src/libs/cplusplus/NamePrettyPrinter.cpp index 99498ae4923..6195302178c 100644 --- a/src/libs/cplusplus/NamePrettyPrinter.cpp +++ b/src/libs/cplusplus/NamePrettyPrinter.cpp @@ -80,8 +80,13 @@ void NamePrettyPrinter::visit(const TemplateNameId *name) if (index != 0) _name += QLatin1String(", "); - FullySpecifiedType argTy = name->templateArgumentAt(index).type(); - QString arg = overview()->prettyType(argTy); + TemplateArgument templArg = name->templateArgumentAt(index); + QString arg; + if (templArg.type().isValid()) + arg = overview()->prettyType(templArg.type()); + else if (const NumericLiteral *num = templArg.numericLiteral()) + arg = QString::fromLatin1(num->chars(), num->size()); + if (arg.isEmpty()) _name += QString::fromLatin1("_Tp%1").arg(index + 1); else