You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-05 12:10:55 +00:00
GDScript: don't check types on release builds
A lot of information is missing on release, and the checks might take a performance hit. Also, having GDScript more lenient on release is usually desirable.
This commit is contained in:
@@ -8110,6 +8110,7 @@ Error GDScriptParser::_parse(const String &p_base_path) {
|
|||||||
check_types = false;
|
check_types = false;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifdef DEBUG_ENABLED
|
||||||
// Resolve all class-level stuff before getting into function blocks
|
// Resolve all class-level stuff before getting into function blocks
|
||||||
_check_class_level_types(main_class);
|
_check_class_level_types(main_class);
|
||||||
|
|
||||||
@@ -8124,7 +8125,6 @@ Error GDScriptParser::_parse(const String &p_base_path) {
|
|||||||
return ERR_PARSE_ERROR;
|
return ERR_PARSE_ERROR;
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef DEBUG_ENABLED
|
|
||||||
// Resolve warning ignores
|
// Resolve warning ignores
|
||||||
Vector<Pair<int, String> > warning_skips = tokenizer->get_warning_skips();
|
Vector<Pair<int, String> > warning_skips = tokenizer->get_warning_skips();
|
||||||
bool warning_is_error = GLOBAL_GET("debug/gdscript/warnings/treat_warnings_as_errors").booleanize();
|
bool warning_is_error = GLOBAL_GET("debug/gdscript/warnings/treat_warnings_as_errors").booleanize();
|
||||||
|
|||||||
Reference in New Issue
Block a user