Ruby  2.0.0p247(2013-06-27revision41674)
Data Structures | Functions | Variables
ext/fiddle/closure.c File Reference
#include <fiddle.h>

Go to the source code of this file.

Data Structures

struct  fiddle_closure

Functions

static void dealloc (void *ptr)
static size_t closure_memsize (const void *ptr)
void callback (ffi_cif *cif, void *resp, void **args, void *ctx)
static VALUE allocate (VALUE klass)
static VALUE initialize (int rbargc, VALUE argv[], VALUE self)
static VALUE to_i (VALUE self)
void Init_fiddle_closure ()

Variables

VALUE cFiddleClosure
const rb_data_type_t closure_data_type

Function Documentation

static VALUE allocate ( VALUE  klass) [static]

Definition at line 166 of file closure.c.

References fiddle_closure::code, NULL, fiddle_closure::pcl, and TypedData_Make_Struct.

Referenced by Init_fiddle_closure().

void callback ( ffi_cif *  cif,
void *  resp,
void **  args,
void *  ctx 
)
static size_t closure_memsize ( const void *  ptr) [static]

Definition at line 31 of file closure.c.

References fiddle_closure::argv, fiddle_closure::cif, and size.

static void dealloc ( void *  ptr) [static]

Definition at line 18 of file closure.c.

References fiddle_closure::argv, fiddle_closure::pcl, and xfree().

static VALUE initialize ( int  rbargc,
VALUE  argv[],
VALUE  self 
) [static]
static VALUE to_i ( VALUE  self) [static]

Definition at line 244 of file closure.c.

References fiddle_closure::code, PTR2NUM, and TypedData_Get_Struct.

Referenced by Init_fiddle_closure().


Variable Documentation

Definition at line 3 of file closure.c.

Referenced by Init_fiddle_closure().

Initial value:
 {
    "fiddle/closure",
    {0, dealloc, closure_memsize,},
}

Definition at line 47 of file closure.c.