Open kz-n opened 2 years ago
I think this would cause problems with function definition, but perhaps there may be a way around it.
GDScript is primary an indented language, and uses whitespace for the parser.
Any thoughts about how to get around that restriction?
func _enter_tree(): print("hi")
This works in Godot 4, I just tested and it indeed doesn't work on 3x, It still is possible to condense new lines with ; on those versions though, So maybe only add a new line after the function definition but keep all the rest inline
This should be pretty easy to accomplish. I haven't actually finished the new construction method yet (AST) as I've been working on other projects.
When I need this I will push for a completion. In general when re-compiling it should be easy to strip out the extra newlines.
Now that I think about it, this is probably unnecessary, especially with compiled GDScript
Instead of keeping newlines, where possible, replace with
;