1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00
ruby--ruby/ext/-test-/random/init.c
Nobuyoshi Nakada af5e87ab21 separate rb_random_t
* random.c: separate abstract rb_random_t and rb_random_mt_t for
  Mersenne Twister implementation.

* include/ruby/random.h: the interface for extensions of Random
  class.

* DLL imported symbol reference is not constant on Windows.

* check if properly initialized.
2020-09-07 20:08:01 +09:00

11 lines
308 B
C

#include "ruby.h"
#define init(n) {void Init_random_##n(VALUE mod, VALUE base); Init_random_##n(mod, base);}
void
Init_random(void)
{
VALUE base = rb_const_get(rb_cRandom, rb_intern_const("Base"));
VALUE mod = rb_define_module_under(rb_define_module("Bug"), "Random");
TEST_INIT_FUNCS(init);
}