summaryrefslogtreecommitdiff
path: root/internal.h
diff options
context:
space:
mode:
author卜部昌平 <shyouhei@ruby-lang.org>2022-07-06 09:18:28 +0900
committer卜部昌平 <shyouhei@ruby-lang.org>2022-07-07 22:10:53 +0900
commit7f64989e5c913ef7624e084badd1a43ce65b3ccc (patch)
treeabb19e527b8084c6a97eca1d775362901733ea45 /internal.h
parent8794cc62899c6447fa4451489b9e308e2a890595 (diff)
do not define our own version of memcpy
The (sole) use of memcpy in our public header is now replaced to directly call ruby_nonempty_memcpy, and the previous definition of memcpy is now internal-only. [Bug#18893]
Notes
Notes: Merged: https://github.com/ruby/ruby/pull/6098
Diffstat (limited to 'internal.h')
-rw-r--r--internal.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/internal.h b/internal.h
index 00a8295295..236d68524c 100644
--- a/internal.h
+++ b/internal.h
@@ -106,4 +106,7 @@ RUBY_SYMBOL_EXPORT_END
#define RBOOL(v) ((v) ? Qtrue : Qfalse)
#define RB_BIGNUM_TYPE_P(x) RB_TYPE_P((x), T_BIGNUM)
+#ifndef __MINGW32__
+#define memcpy ruby_nonempty_memcpy
+#endif
#endif /* RUBY_INTERNAL_H */