diff options
author | Francois Belair <razoric480@gmail.com> | 2021-11-07 12:20:25 -0500 |
---|---|---|
committer | Francois Belair <razoric480@gmail.com> | 2021-11-07 12:20:25 -0500 |
commit | 4995a477ffcb1b11b8de0e2e09d0749de38ceef4 (patch) | |
tree | 9224ef91949e8674b66d1cfbb7b8e97aca76aaf3 /modules | |
parent | 9f46ce86523e01435ad34de467de586485448278 (diff) |
Fix LSP crash when parsing signal symbols.
If the number of parameters was less than the number of class members, the LSP would cause godot to crash because it was using the index for class members instead of the index for signal parameters.
Fixes #54720 .
Diffstat (limited to 'modules')
-rw-r--r-- | modules/gdscript/language_server/gdscript_extend_parser.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/gdscript/language_server/gdscript_extend_parser.cpp b/modules/gdscript/language_server/gdscript_extend_parser.cpp index f4c0c4d9bb..80f4721e2d 100644 --- a/modules/gdscript/language_server/gdscript_extend_parser.cpp +++ b/modules/gdscript/language_server/gdscript_extend_parser.cpp @@ -269,7 +269,7 @@ void ExtendGDScriptParser::parse_class_symbol(const GDScriptParser::ClassNode *p if (j > 0) { symbol.detail += ", "; } - symbol.detail += m.signal->parameters[i]->identifier->name; + symbol.detail += m.signal->parameters[j]->identifier->name; } symbol.detail += ")"; |