Ruby  1.9.3p547(2014-05-14revision45962)
bug.c
Go to the documentation of this file.
1 #include <ruby.h>
2 
3 static VALUE
5 {
7  return ID2SYM(rb_frame_this_func());
8 }
9 
10 static VALUE
12 {
13  VALUE ary = rb_ary_new3(1, Qnil);
14  rb_block_call(ary, rb_intern("map"), 0, 0, bug_i, self);
15  return ary;
16 }
17 
18 void
19 Init_bug(void)
20 {
21  VALUE mBug = rb_define_module("Bug");
22  rb_define_module_function(mBug, "start", bug_start, 0);
23 }
int i
Definition: win32ole.c:776
#define rb_block_call(arg1, arg2, arg3, arg4, arg5, arg6)
Definition: ruby_missing.h:38
ID rb_frame_this_func(void)
Definition: eval.c:801
VALUE rb_ary_new3(long n,...)
Definition: array.c:347
#define ID2SYM(i)
Definition: cparse.c:63
static VALUE bug_start(VALUE self, VALUE hash)
Definition: bug.c:11
arg
Definition: ripper.y:1287
void Init_bug(void)
Definition: bug.c:19
void rb_define_module_function(VALUE module, const char *name, VALUE(*func)(ANYARGS), int argc)
Defines a module function for module.
Definition: class.c:1358
#define Qnil
Definition: ruby.h:367
unsigned long VALUE
Definition: ruby.h:88
static VALUE bug_i(VALUE i, VALUE arg)
Definition: bug.c:4
void rb_notimplement(void)
Definition: error.c:1598
static unsigned int hash(const char *str, unsigned int len)
Definition: lex.c:56
VALUE rb_define_module(const char *name)
Definition: class.c:587
#define rb_intern(str)