/* method: to_type(type) */ static VALUE na_to_type(VALUE self, VALUE vtype) { struct NARRAY *a1, *a2; VALUE v; GetNArray(self,a1); v = na_make_object(na_get_typecode(vtype), a1->rank, a1->shape, CLASS_OF(self)); GetNArray(v,a2); na_copy_nary(a2,a1); return v; }