From: ts Date: 2001-01-21T22:02:12+09:00 Subject: [ruby-talk:9650] Re: using procs and blocks from C >>>>> "A" == Avi Bryant writes: A> On Sun, 21 Jan 2001, ts wrote: >> rb_scan_args(argc, argv, "12*&", ...); A> Sorry... are you actually saying I can use that somehow when *calling* a A> method with a block? If you put "&" at the end ruby will do : if (*p == '&') { var = va_arg(vargs, VALUE*); if (rb_block_given_p()) { *var = rb_f_lambda(); } else { *var = Qnil; } p++; This is exactly the same thing than when you write : def toto(a, b, &block) Guy Decoux