forked from qt-creator/qt-creator
Clang: Fix cursor position after completion of overloads
struct Foo {
void begin();
void begin() const;
};
void c(Foo &foo)
{
foo.beg // complete to foo.begin()| instead of foo.begin(|)
}
Task-number: QTCREATORBUG-17443
Change-Id: I60ca16bbfeeb75c5c37a0d5bc6f46e9e9913b86e
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
This commit is contained in:
@@ -89,7 +89,8 @@ QList<AssistProposalItemInterface *> toAssistProposalItems(const CodeCompletions
|
||||
|
||||
ClangAssistProposalItem *item = items.value(name, 0);
|
||||
if (item) {
|
||||
item->addOverload(codeCompletion);
|
||||
if (codeCompletion.hasParameters())
|
||||
item->setHasOverloadsWithParameters(true);
|
||||
} else {
|
||||
item = new ClangAssistProposalItem;
|
||||
items.insert(name, item);
|
||||
|
||||
Reference in New Issue
Block a user