From baa94a375858e80bf9424fd895e3384edb4e114c Mon Sep 17 00:00:00 2001 From: "Wilson E. Alvarez" Date: Tue, 22 Aug 2017 13:01:57 -0400 Subject: Removed unnecessary returns and break statements --- modules/gdscript/gd_function.h | 3 ++- modules/gdscript/gd_script.cpp | 3 ++- modules/visual_script/visual_script_expression.cpp | 1 - 3 files changed, 4 insertions(+), 3 deletions(-) (limited to 'modules') diff --git a/modules/gdscript/gd_function.h b/modules/gdscript/gd_function.h index 6d20b19777..661de0acce 100644 --- a/modules/gdscript/gd_function.h +++ b/modules/gdscript/gd_function.h @@ -210,8 +210,9 @@ public: #ifdef TOOLS_ENABLED ERR_FAIL_INDEX_V(p_idx, arg_names.size(), StringName()); return arg_names[p_idx]; -#endif +#else return StringName(); +#endif } Variant get_default_argument(int p_idx) const { ERR_FAIL_INDEX_V(p_idx, default_arguments.size(), Variant()); diff --git a/modules/gdscript/gd_script.cpp b/modules/gdscript/gd_script.cpp index 2d06c0f5d2..23201dc1b0 100644 --- a/modules/gdscript/gd_script.cpp +++ b/modules/gdscript/gd_script.cpp @@ -559,8 +559,9 @@ bool GDScript::_update_exports() { return changed; -#endif +#else return false; +#endif } void GDScript::update_exports() { diff --git a/modules/visual_script/visual_script_expression.cpp b/modules/visual_script/visual_script_expression.cpp index 78b70934c0..25c2ebd6d2 100644 --- a/modules/visual_script/visual_script_expression.cpp +++ b/modules/visual_script/visual_script_expression.cpp @@ -585,7 +585,6 @@ Error VisualScriptExpression::_get_token(Token &r_token) { r_token.type = TK_BASIC_TYPE; r_token.value = i; return OK; - break; } } -- cgit v1.2.3