From: Andre Nathan Date: 2006-08-28T02:47:20+09:00 Subject: Re: Passing blocks around in a C extension On Mon, 2006-08-28 at 02:06 +0900, ts wrote: > Proc.new is rb_block_proc() > block_given? is rb_block_given_p() Thanks Guy! Now, it must be something stupid, but this works: func_with_callback(..., my_callback, (void *)rb_block_proc()); and this segfaults: VALUE block = rb_block_proc(); func_with_callback(..., my_callback, (void *)block); Any idea why? I don't really need the second form, but it kinda puzzled me. Thanks again, Andre