Merge pull request #62699 from cdemirer/fix-autocomplete-var-assigned-same-statement

This commit is contained in:
Rémi Verschelde 2022-07-06 15:57:19 +02:00 committed by GitHub
commit fdff28e1a2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1855,7 +1855,7 @@ static bool _guess_identifier_type(GDScriptParser::CompletionContext &p_context,
while (suite) {
for (int i = 0; i < suite->statements.size(); i++) {
if (suite->statements[i]->start_line > p_context.current_line) {
if (suite->statements[i]->end_line >= p_context.current_line) {
break;
}