From: ts Date: 2002-04-19T00:59:26+09:00 Subject: Re: Confused by example in Pickaxe book >>>>> "D" == Daniel Berger writes: D> First, isn't that 2 arguments instead of 1 (remembering to exclude Well, you are at C level if you don't give the object ruby will not know which method call D> 'self', i.e. tdata, as an argument). What is the '1' for? The prototype is rb_obj_call_init(VALUE obj, int argc, VALUE *argv) `1' is for the number of elements in argv D> VALUE argv[1]; D> argv[0] = unit; To have a VALUE * to give it to rb_obj_call_init(), In this case it can be written rb_obj_call_init(tdata, 1, &unit); Guy Decoux