&block question

Discussion in 'Ruby' started by John Mair, Aug 9, 2008.

  1. John Mair

    John Mair Guest

    Hello friends,

    I'm having a hard time implementing the equivalent of this in the ruby
    C API:

    module M
    module_function
    def run(&block)
    module_eval(&block)
    end
    end

    How is the &block operation implemented in the C API? im looking for
    something to convert a proc to a
    block. i've scanned many of the .c files and have found nothing.
    Anyone have any ideas?

    cheers

    John
    --
    Posted via http://www.ruby-forum.com/.
    John Mair, Aug 9, 2008
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Showjumper
    Replies:
    1
    Views:
    686
    Showjumper
    Mar 19, 2005
  2. Noozer

    Block DIV within a block DIV?

    Noozer, Jan 6, 2005, in forum: HTML
    Replies:
    3
    Views:
    11,344
    Mitja
    Jan 6, 2005
  3. Andy
    Replies:
    0
    Views:
    519
  4. morrell
    Replies:
    1
    Views:
    926
    roy axenov
    Oct 10, 2006
  5. Alvin
    Replies:
    8
    Views:
    951
Loading...

Share This Page