mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
2.Replace mrb_intern() func with mrb_intern2() func or mrb_intern_cstr() func.
This commit is contained in:
+1
-1
@@ -1101,5 +1101,5 @@ mrb_init_kernel(mrb_state *mrb)
|
||||
mrb_define_method(mrb, krn, "to_s", mrb_any_to_s, MRB_ARGS_NONE()); /* 15.3.1.3.46 */
|
||||
|
||||
mrb_include_module(mrb, mrb->object_class, mrb->kernel_module);
|
||||
mrb_alias_method(mrb, mrb->module_class, mrb_intern(mrb, "dup"), mrb_intern(mrb, "clone"));
|
||||
mrb_alias_method(mrb, mrb->module_class, mrb_intern2(mrb, "dup", 3), mrb_intern2(mrb, "clone", 5));
|
||||
}
|
||||
|
||||
@@ -279,7 +279,7 @@ ecall(mrb_state *mrb, int i)
|
||||
mrb_value
|
||||
mrb_funcall(mrb_state *mrb, mrb_value self, const char *name, int argc, ...)
|
||||
{
|
||||
mrb_sym mid = mrb_intern(mrb, name);
|
||||
mrb_sym mid = mrb_intern_cstr(mrb, name);
|
||||
|
||||
if (argc == 0) {
|
||||
return mrb_funcall_argv(mrb, self, mid, 0, 0);
|
||||
|
||||
Reference in New Issue
Block a user