Ruby 1.9.2p136(2010-12-25revision30365)

- Main Page
- Modules
- Data Structures
- Files

- File List
- Globals

# ext/dl/callback/callback.c

Go to the documentation of this file.

    00001 #include "ruby.h"
    00002
    00003 VALUE rb_DLCdeclCallbackAddrs, rb_DLCdeclCallbackProcs;
    00004 #ifdef FUNC_STDCALL
    00005 VALUE rb_DLStdcallCallbackAddrs, rb_DLStdcallCallbackProcs;
    00006 #endif
    00007 /*static void *cdecl_callbacks[MAX_DLTYPE][MAX_CALLBACK];*/
    00008 #ifdef FUNC_STDCALL
    00009 /*static void *stdcall_callbacks[MAX_DLTYPE][MAX_CALLBACK];*/
    00010 #endif
    00011 ID   rb_dl_cb_call;
    00012 void rb_dl_init_callbacks_0();
    00013 void rb_dl_init_callbacks_1();
    00014 void rb_dl_init_callbacks_2();
    00015 void rb_dl_init_callbacks_3();
    00016 void rb_dl_init_callbacks_4();
    00017 void rb_dl_init_callbacks_5();
    00018 void rb_dl_init_callbacks_6();
    00019 void rb_dl_init_callbacks_7();
    00020 void rb_dl_init_callbacks_8();
    00021 void
    00022 Init_callback(void)
    00023 {
    00024     VALUE tmp;
    00025     VALUE rb_mDL = rb_path2class("DL");
    00026
    00027     rb_dl_cb_call = rb_intern("call");
    00028
    00029     tmp = rb_DLCdeclCallbackProcs = rb_ary_new();
    00030     rb_define_const(rb_mDL, "CdeclCallbackProcs", tmp);
    00031
    00032     tmp = rb_DLCdeclCallbackAddrs = rb_ary_new();
    00033     rb_define_const(rb_mDL, "CdeclCallbackAddrs", tmp);
    00034
    00035 #ifdef FUNC_STDCALL
    00036     tmp = rb_DLStdcallCallbackProcs = rb_ary_new();
    00037     rb_define_const(rb_mDL, "StdcallCallbackProcs", tmp);
    00038
    00039     tmp = rb_DLStdcallCallbackAddrs = rb_ary_new();
    00040     rb_define_const(rb_mDL, "StdcallCallbackAddrs", tmp);
    00041 #endif
    00042
    00043     rb_dl_init_callbacks_0();
    00044     rb_dl_init_callbacks_1();
    00045     rb_dl_init_callbacks_2();
    00046     rb_dl_init_callbacks_3();
    00047     rb_dl_init_callbacks_4();
    00048     rb_dl_init_callbacks_5();
    00049     rb_dl_init_callbacks_6();
    00050     rb_dl_init_callbacks_7();
    00051     rb_dl_init_callbacks_8();
    00052 }
    00053