2002/3/22
4.
構造体をクラスにラップする
(6)
n
%typemap(in) gsl_vector *input {
n
Data_Get_Struct($input, $1_basetype, $1);
n
}
n
input
は他のオブジェクトから構造体を受け取る
n
n
%typemap(out) gsl_vector * {
n
$result = Data_Wrap_Struct(c$1_basetype, 0, $1_basetype_free, $1);
n
}
n
関数の返り値が構造体という場合に対応