Ruby 1.9.2p136(2010-12-25revision30365)

- Main Page
- Modules
- Data Structures
- Files

- File List
- Globals

# goruby.c

Go to the documentation of this file.

    00001 void Init_golf(void);
    00002 #define ruby_run_node goruby_run_node
    00003 #include "main.c"
    00004 #undef ruby_run_node
    00005
    00006 RUBY_EXTERN int ruby_run_node(void*);
    00007 RUBY_EXTERN void ruby_init_ext(const char *name, void (*init)(void));
    00008
    00009 static VALUE
    00010 init_golf(VALUE arg)
    00011 {
    00012     ruby_init_ext("golf", Init_golf);
    00013     return arg;
    00014 }
    00015
    00016 int
    00017 goruby_run_node(void *arg)
    00018 {
    00019     int state;
    00020     if (NIL_P(rb_protect(init_golf, Qtrue, &state))) {
    00021         return state == EXIT_SUCCESS ? EXIT_FAILURE : state;
    00022     }
    00023     return ruby_run_node(arg);
    00024 }
    00025