diff options
author | RĂ©mi Verschelde <rverschelde@gmail.com> | 2020-01-08 18:22:38 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-01-08 18:22:38 +0100 |
commit | c456d87ee60ec0609b21ff0476a06efaaae21719 (patch) | |
tree | c81b699f6f4766e503099774b4b78e565de4baa1 /modules/gdscript/gdscript_functions.cpp | |
parent | fb31283960e0e62df6d7d23955b73d8140809ecb (diff) | |
parent | d26414f9fe62e55af75dd9191ea602c8493640cc (diff) |
Merge pull request #34918 from vnen/gdscript-assign-op
GDScript: enable type checks on release mode
Diffstat (limited to 'modules/gdscript/gdscript_functions.cpp')
-rw-r--r-- | modules/gdscript/gdscript_functions.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/modules/gdscript/gdscript_functions.cpp b/modules/gdscript/gdscript_functions.cpp index e0e95f259e..01d62a1c62 100644 --- a/modules/gdscript/gdscript_functions.cpp +++ b/modules/gdscript/gdscript_functions.cpp @@ -2057,12 +2057,13 @@ MethodInfo GDScriptFunctions::get_info(Function p_func) { mi.return_val.type = Variant::BOOL; return mi; } break; - case FUNC_MAX: { + default: { ERR_FAIL_V(MethodInfo()); } break; } #endif - - return MethodInfo(); + MethodInfo mi; + mi.return_val.usage |= PROPERTY_USAGE_NIL_IS_VARIANT; + return mi; } |