CppEditor: Expand templates for Qt5 connect conversion

Fixes at least explicit data() calls for templated pointers:

QPointer<QAction> action;
connect(action.data(), SIGNAL(triggered()), this, SLOT(slot()));

Change-Id: I7f76c1f556c0f271936728d611751424969916a7
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@theqtcompany.com>
This commit is contained in:
Orgad Shaneh
2015-03-05 22:17:56 +02:00
committed by Orgad Shaneh
parent ef894f21e2
commit 683540bee7
2 changed files with 12 additions and 0 deletions

View File

@@ -5592,6 +5592,7 @@ Class *senderOrReceiverClass(const CppQuickFixInterface &interface,
objectPointerExpression = "this";
TypeOfExpression toe;
toe.setExpandTemplates(true);
toe.init(interface.semanticInfo().doc, interface.snapshot(), context.bindings());
const QList<LookupItem> objectPointerExpressions = toe(objectPointerExpression,
objectPointerScope, TypeOfExpression::Preprocess);