summaryrefslogtreecommitdiff
path: root/src/plugins/cppeditor/cpphoverhandler.cpp
diff options
context:
space:
mode:
authorRoberto Raggi <roberto.raggi@nokia.com>2009-11-17 14:21:46 +0100
committerRoberto Raggi <roberto.raggi@nokia.com>2009-11-17 14:24:09 +0100
commitecf40d24260c7a407e365a2265d8caaf0bfbabff (patch)
treeb757344d1839b7dbffff6b1f932ef7d891698034 /src/plugins/cppeditor/cpphoverhandler.cpp
parent5d7def6d2ad8be72f4b6e1255a779209dbe90ff8 (diff)
downloadqt-creator-ecf40d24260c7a407e365a2265d8caaf0bfbabff.tar.gz
Get rid off QPair<FullySpecifiedType, Symbol *>. Use LookupItem intead.
Diffstat (limited to 'src/plugins/cppeditor/cpphoverhandler.cpp')
-rw-r--r--src/plugins/cppeditor/cpphoverhandler.cpp11
1 files changed, 5 insertions, 6 deletions
diff --git a/src/plugins/cppeditor/cpphoverhandler.cpp b/src/plugins/cppeditor/cpphoverhandler.cpp
index ff671da25a..6c93ca8ffa 100644
--- a/src/plugins/cppeditor/cpphoverhandler.cpp
+++ b/src/plugins/cppeditor/cpphoverhandler.cpp
@@ -323,14 +323,13 @@ void CppHoverHandler::updateHelpIdAndTooltip(TextEditor::ITextEditor *editor, in
ExpressionUnderCursor expressionUnderCursor;
const QString expression = expressionUnderCursor(tc);
- const QList<TypeOfExpression::Result> types =
- typeOfExpression(expression, doc, lastSymbol);
+ const QList<LookupItem> types = typeOfExpression(expression, doc, lastSymbol);
if (!types.isEmpty()) {
- const TypeOfExpression::Result result = types.first();
+ const LookupItem result = types.first();
- FullySpecifiedType firstType = result.first; // result of `type of expression'.
- Symbol *lookupSymbol = result.second; // lookup symbol
+ FullySpecifiedType firstType = result.type(); // result of `type of expression'.
+ Symbol *lookupSymbol = result.lastVisibleSymbol(); // lookup symbol
Symbol *resolvedSymbol = lookupSymbol;
Name *resolvedName = lookupSymbol ? lookupSymbol->name() : 0;
@@ -349,7 +348,7 @@ void CppHoverHandler::updateHelpIdAndTooltip(TextEditor::ITextEditor *editor, in
m_helpId = buildHelpId(resolvedSymbol, resolvedName);
if (m_toolTip.isEmpty()) {
- Symbol *symbol = result.second;
+ Symbol *symbol = result.lastVisibleSymbol();
if (resolvedSymbol)
symbol = resolvedSymbol;