Groonga 3.0.9 Source Code Document
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
example.c
Go to the documentation of this file.
1 #include <mruby.h>
2 #include <stdio.h>
3 
4 static mrb_value
5 mrb_c_method(mrb_state *mrb, mrb_value self)
6 {
7  puts("A C Extension");
8  return self;
9 }
10 
11 void
13  struct RClass *class_cextension = mrb_define_module(mrb, "CRubyExtension");
14  mrb_define_class_method(mrb, class_cextension, "c_method", mrb_c_method, MRB_ARGS_NONE());
15 }
16 
17 void
19  // finalizer
20 }