forked from qt-creator/qt-creator
Clang: Treat brace initialization as constructor completion
Try to complete constructor after left brace with fallback to normal completion. Task-number: QTCREATORBUG-20957 Change-Id: I6c33790a3ee1e623a3d8abe9a44cfd821b6f3106 Reviewed-by: Marco Bubke <marco.bubke@qt.io>
This commit is contained in:
@@ -262,7 +262,7 @@ int ExpressionUnderCursor::startOfFunctionCall(const QTextCursor &cursor) const
|
||||
|
||||
if (tk.is(T_EOF_SYMBOL)) {
|
||||
break;
|
||||
} else if (tk.is(T_LPAREN)) {
|
||||
} else if (tk.is(T_LPAREN) || tk.is(T_LBRACE)) {
|
||||
return scanner.startPosition() + tk.utf16charsBegin();
|
||||
} else if (tk.is(T_RPAREN)) {
|
||||
int matchingBrace = scanner.startOfMatchingBrace(index);
|
||||
|
||||
Reference in New Issue
Block a user