Merge pull request #64717 from Chaosus/gds_fix_param_completion

This commit is contained in:
Yuri Rubinsky 2022-09-30 18:34:33 +03:00 committed by GitHub
commit 6f75b0d79b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -2937,6 +2937,10 @@ GDScriptParser::ExpressionNode *GDScriptParser::parse_call(ExpressionNode *p_pre
push_error(R"(Expected expression as the function argument.)");
} else {
call->arguments.push_back(argument);
if (argument->type == Node::IDENTIFIER && current.cursor_place == GDScriptTokenizer::CURSOR_BEGINNING) {
completion_context.type = COMPLETION_IDENTIFIER;
}
}
ct = COMPLETION_CALL_ARGUMENTS;
} while (match(GDScriptTokenizer::Token::COMMA));