diff options
author | Rémi Verschelde <rverschelde@gmail.com> | 2021-04-27 16:19:21 +0200 |
---|---|---|
committer | Rémi Verschelde <rverschelde@gmail.com> | 2021-04-27 16:26:27 +0200 |
commit | 8247667a3ee0d86f26094e722497b0cbb99cc12b (patch) | |
tree | d03fb75cca2ad4dd63d3c55e1d6ecde074441182 /core/object | |
parent | 288f484d0a034d02fbca3db0a2f14f5a0084a36b (diff) |
Core: Drop custom `copymem`/`zeromem` defines
We've been using standard C library functions `memcpy`/`memset` for these since
2016 with 67f65f66391327b2967a20a89c3627e1dd6e84eb.
There was still the possibility for third-party platform ports to override the
definitions with a custom header, but this doesn't seem useful anymore.
Diffstat (limited to 'core/object')
-rw-r--r-- | core/object/callable_method_pointer.h | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/core/object/callable_method_pointer.h b/core/object/callable_method_pointer.h index 115797a00c..8ba01be4e4 100644 --- a/core/object/callable_method_pointer.h +++ b/core/object/callable_method_pointer.h @@ -32,7 +32,6 @@ #define CALLABLE_METHOD_POINTER_H #include "core/object/object.h" -#include "core/os/copymem.h" #include "core/templates/hashfuncs.h" #include "core/templates/simple_type.h" #include "core/variant/binder_common.h" @@ -98,7 +97,7 @@ public: } CallableCustomMethodPointer(T *p_instance, void (T::*p_method)(P...)) { - zeromem(&data, sizeof(Data)); // Clear beforehand, may have padding bytes. + memset(&data, 0, sizeof(Data)); // Clear beforehand, may have padding bytes. data.instance = p_instance; #ifdef DEBUG_ENABLED data.object_id = p_instance->get_instance_id(); @@ -153,7 +152,7 @@ public: } CallableCustomMethodPointerRet(T *p_instance, R (T::*p_method)(P...)) { - zeromem(&data, sizeof(Data)); // Clear beforehand, may have padding bytes. + memset(&data, 0, sizeof(Data)); // Clear beforehand, may have padding bytes. data.instance = p_instance; #ifdef DEBUG_ENABLED data.object_id = p_instance->get_instance_id(); @@ -208,7 +207,7 @@ public: } CallableCustomMethodPointerRetC(T *p_instance, R (T::*p_method)(P...) const) { - zeromem(&data, sizeof(Data)); // Clear beforehand, may have padding bytes. + memset(&data, 0, sizeof(Data)); // Clear beforehand, may have padding bytes. data.instance = p_instance; #ifdef DEBUG_ENABLED data.object_id = p_instance->get_instance_id(); |