summaryrefslogtreecommitdiff
path: root/modules/gdscript/language_server
diff options
context:
space:
mode:
authorHugo Locurcio <hugo.locurcio@hugo.pro>2019-09-23 15:27:30 +0200
committerHugo Locurcio <hugo.locurcio@hugo.pro>2019-09-23 15:27:30 +0200
commitc1fcb22677b519eb22f8117fecf1a84b11c84bc2 (patch)
treea6dd4ff301e799afe27393b51700259134ab1f6b /modules/gdscript/language_server
parent159470df08c0283a2330af94d26ccbe3d009d8fd (diff)
Fix `line` being assigned to twice in the GDScript language server
This closes #32090.
Diffstat (limited to 'modules/gdscript/language_server')
-rw-r--r--modules/gdscript/language_server/gdscript_extend_parser.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/modules/gdscript/language_server/gdscript_extend_parser.cpp b/modules/gdscript/language_server/gdscript_extend_parser.cpp
index 9e8727ec58..6db8cb2c88 100644
--- a/modules/gdscript/language_server/gdscript_extend_parser.cpp
+++ b/modules/gdscript/language_server/gdscript_extend_parser.cpp
@@ -345,15 +345,13 @@ String ExtendGDScriptParser::marked_documentation(const String &p_bbcode) {
if (block_start != -1) {
code_block_indent = block_start;
in_code_block = true;
- line = "'''gdscript";
- line = "\n";
+ line = "'''gdscript\n";
} else if (in_code_block) {
line = "\t" + line.substr(code_block_indent, line.length());
}
if (in_code_block && line.find("[/codeblock]") != -1) {
- line = "'''\n";
- line = "\n";
+ line = "'''\n\n";
in_code_block = false;
}