コード例 #1
0
 public static VALUE Allocate(VALUE klass)
 {
     try
     {
         VALUE obj = Ruby.Data_Wrap_Struct(klass, null, FreeFunc, IntPtr.Zero);
         return(obj);
     }
     catch (Exception exception)
     {
         Ruby.rb_raise(Ruby.rb_eException, exception.Message);
         return(Ruby.Qnil);
     }
 }