Commit 81ea89f1 authored by dearblue's avatar dearblue

Need explicit cast for C++

parent 3b061a90
...@@ -41,7 +41,7 @@ MRB_API struct RData *mrb_data_object_alloc(mrb_state *mrb, struct RClass* klass ...@@ -41,7 +41,7 @@ MRB_API struct RData *mrb_data_object_alloc(mrb_state *mrb, struct RClass* klass
#define Data_Make_Struct(mrb,klass,strct,type,sval,data_obj) do { \ #define Data_Make_Struct(mrb,klass,strct,type,sval,data_obj) do { \
(data_obj) = Data_Wrap_Struct(mrb,klass,type,NULL);\ (data_obj) = Data_Wrap_Struct(mrb,klass,type,NULL);\
(sval) = mrb_malloc(mrb, sizeof(strct)); \ (sval) = (strct *)mrb_malloc(mrb, sizeof(strct)); \
{ static const strct zero = { 0 }; *(sval) = zero; };\ { static const strct zero = { 0 }; *(sval) = zero; };\
(data_obj)->data = (sval);\ (data_obj)->data = (sval);\
} while (0) } while (0)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment