Enable MRB_METHOD_T_STRUCT by default on 32bit GUN/Linux

Because we can't use the highest 2 bits of function pointers.
This commit is contained in:
Horimoto Yasuhiro
2020-04-30 16:22:23 +09:00
parent 84aad39940
commit a5bfe548d7
+3 -2
View File
@@ -39,8 +39,9 @@
/* add -DMRB_METHOD_T_STRUCT on machines that use higher bits of pointers */
/* no MRB_METHOD_T_STRUCT requires highest 2 bits of function pointers to be zero */
#ifndef MRB_METHOD_T_STRUCT
// can't use highest 2 bits of function pointers on 32bit Windows.
# if defined(_WIN32) && !defined(_WIN64)
// can't use highest 2 bits of function pointers at least on 32bit
// Windows and 32bit Linux.
# ifdef MRB_32BIT
# define MRB_METHOD_T_STRUCT
# endif
#endif