From: matz@... (Yukihiro Matsumoto) Date: 2002-10-21T10:20:43+09:00 Subject: Re: rb_class_new_instance question Hi, In message "rb_class_new_instance question" on 02/10/21, "Tim Hunter" writes: |However, if I create a new instance from C using rb_class_new_instance, |the statement "@scene = nil" causes the length attribute to become a |very large value. self.length may be 135674608, for example (but it's |not necessarily the same from time to time). Unfortunately rb_class_new_instance() only creates T_OBJECT objects, but Arrays are T_ARRAY objects. If you are using 1.7, you can call rb_obj_alloc() for your purpose. matz.