You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The GDScript editor shows errors very clearly, but there's no system in place to show warnings. I believe it would be very beneficial and help find some bugs in user code. For instance, some examples of what could be caught:
With a static typing system is also possible to catch other problems:
Integer division (such as 3 / 7, which becomes zero).
Narrowing conversion (passing a float to a function that uses int).
Discarding the return value of a function call.
And probably other stuff I can't think of right now.
It should show warnings in editor, when possible, and runtime warnings as well. Turning them of on a case might be needed too (sometimes you do want to make an integer division).
The text was updated successfully, but these errors were encountered:
I think Godot might need a separate errors/warnings bottom panel to support easy viewing and double clicking on each of them similar to Visual Studio C++ 'Error List'. It would be kind of like a todo list.
I'm not sure about how to do the interface. Bottom panel sounds fine at first, but it should be easily relatable to the current open script. Warnings will only be caught when parsing so that means it's only meaningful for the edited script, since that's the one still being parsed (also, it should be easy to see the warnings in the current script). It also could show in the console when running the game.
Major problem with bottom panel is that it's hard to add from the script editor plugin. It should remain self-contained. A hidable panel in the editor itself is probably better.
The GDScript editor shows errors very clearly, but there's no system in place to show warnings. I believe it would be very beneficial and help find some bugs in user code. For instance, some examples of what could be caught:
With a static typing system is also possible to catch other problems:
3 / 7
, which becomes zero).float
to a function that usesint
).And probably other stuff I can't think of right now.
It should show warnings in editor, when possible, and runtime warnings as well. Turning them of on a case might be needed too (sometimes you do want to make an integer division).
The text was updated successfully, but these errors were encountered: