1
0
mirror of https://github.com/godotengine/godot synced 2024-07-05 15:43:36 +00:00

Merge pull request #85488 from miv391/fix-expected-indented-block-error-message-lines

Moving "Expected indented block" error message's line number back to where the error is
This commit is contained in:
Rémi Verschelde 2024-06-10 16:11:30 +02:00
commit 09a037628e
No known key found for this signature in database
GPG Key ID: C3336907360768E1

View File

@ -166,7 +166,7 @@ void GDScriptParser::push_error(const String &p_message, const Node *p_origin) {
panic_mode = true;
// TODO: Improve positional information.
if (p_origin == nullptr) {
errors.push_back({ p_message, current.start_line, current.start_column });
errors.push_back({ p_message, previous.start_line, previous.start_column });
} else {
errors.push_back({ p_message, p_origin->start_line, p_origin->leftmost_column });
}