diff options
author | cdemirer <41021322+cdemirer@users.noreply.github.com> | 2022-07-04 10:08:41 +0300 |
---|---|---|
committer | cdemirer <41021322+cdemirer@users.noreply.github.com> | 2022-07-04 10:08:41 +0300 |
commit | 3a827349bfe5cd9bc9b5b76b63fc1132b4a82eda (patch) | |
tree | 220b789a98928e35d1dec061fb6aac5e5549cadf /modules | |
parent | 41fdddb1f8132dcba8256a145de44da5df3155b2 (diff) | |
download | redot-engine-3a827349bfe5cd9bc9b5b76b63fc1132b4a82eda.tar.gz |
Fix autocomplete for variable which is assigned to in the current statement
Diffstat (limited to 'modules')
-rw-r--r-- | modules/gdscript/gdscript_editor.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/gdscript/gdscript_editor.cpp b/modules/gdscript/gdscript_editor.cpp index 474c8094f2..b0d2b11de6 100644 --- a/modules/gdscript/gdscript_editor.cpp +++ b/modules/gdscript/gdscript_editor.cpp @@ -1843,7 +1843,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; } |