Browse Source

Merge pull request #56342 from NNesh/fix/class-completion

Rémi Verschelde 3 years ago
parent
commit
8f8c3f4b4c
1 changed files with 2 additions and 0 deletions
  1. 2 0
      modules/gdscript/gdscript_parser.cpp

+ 2 - 0
modules/gdscript/gdscript_parser.cpp

@@ -817,6 +817,8 @@ void GDScriptParser::parse_class_body(bool p_is_multiline) {
 				class_end = true;
 				class_end = true;
 				break;
 				break;
 			default:
 			default:
+				// Display a completion with identifiers.
+				make_completion_context(COMPLETION_IDENTIFIER, nullptr);
 				push_error(vformat(R"(Unexpected "%s" in class body.)", current.get_name()));
 				push_error(vformat(R"(Unexpected "%s" in class body.)", current.get_name()));
 				advance();
 				advance();
 				break;
 				break;