diff options
author | RĂ©mi Verschelde <remi@verschelde.fr> | 2020-12-15 20:52:03 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-12-15 20:52:03 +0100 |
commit | 94b15bfb893337e545176dfe5c66ced2a6a9aabb (patch) | |
tree | d9797cd9b50f859e0ff62095fdc8981f4c74cf22 /modules/gdscript | |
parent | abfc528439f334eaea91377a46121089aa5be229 (diff) | |
parent | 0abacae2d3102f5b32fb9d060b94d0095382a5df (diff) |
Merge pull request #44275 from vnen/variant-function-arg-pointers
Use pointer parameters in Variant function pointers
Diffstat (limited to 'modules/gdscript')
-rw-r--r-- | modules/gdscript/gdscript_vm.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/modules/gdscript/gdscript_vm.cpp b/modules/gdscript/gdscript_vm.cpp index 88ebb78971..b8e1791467 100644 --- a/modules/gdscript/gdscript_vm.cpp +++ b/modules/gdscript/gdscript_vm.cpp @@ -739,7 +739,7 @@ Variant GDScriptFunction::call(GDScriptInstance *p_instance, const Variant **p_a const Variant::ValidatedKeyedSetter setter = _keyed_setters_ptr[index_setter]; bool valid; - setter(dst, index, value, valid); + setter(dst, index, value, &valid); #ifdef DEBUG_ENABLED if (!valid) { @@ -771,7 +771,7 @@ Variant GDScriptFunction::call(GDScriptInstance *p_instance, const Variant **p_a int64_t int_index = *VariantInternal::get_int(index); bool oob; - setter(dst, int_index, value, oob); + setter(dst, int_index, value, &oob); #ifdef DEBUG_ENABLED if (oob) { @@ -836,9 +836,9 @@ Variant GDScriptFunction::call(GDScriptInstance *p_instance, const Variant **p_a #ifdef DEBUG_ENABLED // Allow better error message in cases where src and dst are the same stack position. Variant ret; - getter(src, key, &ret, valid); + getter(src, key, &ret, &valid); #else - getter(src, key, dst, valid); + getter(src, key, dst, &valid); #endif #ifdef DEBUG_ENABLED if (!valid) { @@ -871,7 +871,7 @@ Variant GDScriptFunction::call(GDScriptInstance *p_instance, const Variant **p_a int64_t int_index = *VariantInternal::get_int(index); bool oob; - getter(src, int_index, dst, oob); + getter(src, int_index, dst, &oob); #ifdef DEBUG_ENABLED if (oob) { @@ -1293,7 +1293,7 @@ Variant GDScriptFunction::call(GDScriptInstance *p_instance, const Variant **p_a GET_INSTRUCTION_ARG(dst, argc); - constructor(*dst, (const Variant **)argptrs); + constructor(dst, (const Variant **)argptrs); ip += 3; } |