You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-05 12:10:55 +00:00
Fix parsing inner class declaration when "pass" keyword is on the same line
Implement a special case for allowing "pass" keyword in one-liner class declaration, to be consistent with Python style. ``` class TestClass: pass ``` This commit fixes #56703
This commit is contained in:
@@ -599,6 +599,9 @@ private:
|
||||
|
||||
bool _parse_arguments(Node *p_parent, Vector<Node *> &p_args, bool p_static, bool p_can_codecomplete = false, bool p_parsing_constant = false);
|
||||
bool _enter_indent_block(BlockNode *p_block = nullptr);
|
||||
bool _enter_inner_class_indent_block();
|
||||
bool _parse_colon();
|
||||
bool _parse_indent_block_newlines(BlockNode *p_block = nullptr);
|
||||
bool _parse_newline();
|
||||
Node *_parse_expression(Node *p_parent, bool p_static, bool p_allow_assign = false, bool p_parsing_constant = false);
|
||||
Node *_reduce_expression(Node *p_node, bool p_to_const = false);
|
||||
|
||||
Reference in New Issue
Block a user