Beispiel #1
0
void
mrb_init_core(mrb_state *mrb)
{
  mrb_init_symtbl(mrb); DONE;

  mrb_init_class(mrb); DONE;
  mrb_init_object(mrb); DONE;
  mrb_init_kernel(mrb); DONE;
  mrb_init_comparable(mrb); DONE;
  mrb_init_enumerable(mrb); DONE;

  mrb_init_symbol(mrb); DONE;
  mrb_init_exception(mrb); DONE;
  mrb_init_proc(mrb); DONE;
  mrb_init_string(mrb); DONE;
  mrb_init_array(mrb); DONE;
  mrb_init_hash(mrb); DONE;
  mrb_init_numeric(mrb); DONE;
  mrb_init_range(mrb); DONE;
#ifdef ENABLE_STRUCT
  mrb_init_struct(mrb); DONE;
#endif
  mrb_init_gc(mrb); DONE;
  mrb_init_regexp(mrb); DONE;
#ifdef ENABLE_STDIO
  mrb_init_print(mrb); DONE;
#endif
#ifdef ENABLE_MATH
  mrb_init_math(mrb); DONE;
#endif
  mrb_init_mrblib(mrb); DONE;
#ifndef DISABLE_GEMS
  mrb_init_mrbgems(mrb); DONE;
#endif
}
Beispiel #2
0
void
mrb_init_core(mrb_state *mrb)
{
  mrb_init_symtbl(mrb); DONE;

  mrb_init_class(mrb); DONE;
  mrb_init_object(mrb); DONE;
  mrb_init_kernel(mrb); DONE;
  mrb_init_comparable(mrb); DONE;
  mrb_init_enumerable(mrb); DONE;

  mrb_init_symbol(mrb); DONE;
  mrb_init_exception(mrb); DONE;
  mrb_init_proc(mrb); DONE;
  mrb_init_string(mrb); DONE;
  mrb_init_array(mrb); DONE;
  mrb_init_hash(mrb); DONE;
  mrb_init_numeric(mrb); DONE;
  mrb_init_range(mrb); DONE;
  mrb_init_gc(mrb); DONE;
  mrb_init_version(mrb); DONE;
  mrb_init_mrblib(mrb); DONE;
#ifndef DISABLE_GEMS
  mrb_init_mrbgems(mrb); DONE;
#endif
}
Beispiel #3
0
void
mrb_init_core(mrb_state *mrb)
{
  mrb_init_symtbl(mrb);

  mrb_init_class(mrb);
  mrb_init_object(mrb);
  mrb_init_kernel(mrb);
  mrb_init_comparable(mrb);
  mrb_init_enumerable(mrb);

  mrb_init_symbols(mrb);
  mrb_init_proc(mrb);
  mrb_init_string(mrb);
  mrb_init_array(mrb);
  mrb_init_hash(mrb);
  mrb_init_numeric(mrb);
  mrb_init_range(mrb);
  mrb_init_struct(mrb);
  mrb_init_gc(mrb);
#ifdef INCLUDE_REGEXP
  mrb_init_regexp(mrb);
#endif
  mrb_init_exception(mrb);
  mrb_init_print(mrb);
  mrb_init_time(mrb);
  mrb_init_math(mrb);

  mrb_init_mrblib(mrb);

  mrb_gc_arena_restore(mrb, 0);
}
Beispiel #4
0
void
mrb_init_core(mrb_state *mrb)
{
  mrb_init_symtbl(mrb);

  mrb_init_class(mrb);
  mrb_init_object(mrb);
  mrb_init_kernel(mrb);
  mrb_init_comparable(mrb);
  mrb_init_enumerable(mrb);

  mrb_init_symbols(mrb);
  mrb_init_proc(mrb);
  mrb_init_string(mrb);
  Init_version(mrb); /* after init_string */
  mrb_init_array(mrb);
  mrb_init_hash(mrb);
  mrb_init_numeric(mrb);
  mrb_init_range(mrb);
  mrb_init_struct(mrb);
  mrb_init_gc(mrb);
#ifdef INCLUDE_REGEXP
  mrb_init_regexp(mrb);
  mrb_init_encoding(mrb);
#endif
  mrb_init_exception(mrb);
  mrb_init_print(mrb);
  mrb_init_time(mrb);

#ifdef MANDEL
  mrb_define_method(mrb, mrb->kernel_module, "pow", mpow, ARGS_REQ(2));
  mrb_define_method(mrb, mrb->kernel_module, "sqrt", msqrt, ARGS_REQ(1));
  mrb_define_method(mrb, mrb->kernel_module, "putc", mputc, ARGS_REQ(1));
#endif

  mrb_init_mrblib(mrb);

  mrb_gc_arena_restore(mrb, 0);
}