Facilitating the spread of knowledge and innovation in professional software development



Choose your language

InfoQ Homepage News Article: Evaluation Options in Ruby

Article: Evaluation Options in Ruby

InfoQ is proud to present a comprehensive discussion of Ruby's various eval methods. This exclusive article is full of rich code examples, written by Domain-Specific Languages master Jay Fields, who after coining the term Business Natural Langages last year, has gone ahead to widespread recognition for his pioneering work in enterprise usage of Ruby and Rails.

In the article, Jay teaches you the capabilities and differences between class_eval, instance_eval and plain eval. His explanation provides insight into how the evaluation methods of Ruby provide very good options for creating concise, readable code.

Read Evaluation Options in Ruby
We need your feedback

How might we improve InfoQ for you

Thank you for being an InfoQ reader.

Each year, we seek feedback from our readers to help us improve InfoQ. Would you mind spending 2 minutes to share your feedback in our short survey? Your feedback will directly help us continually evolve how we support you.

Take the Survey

Rate this Article


Hello stranger!

You need to Register an InfoQ account or or login to post comments. But there's so much more behind being registered.

Get the most out of the InfoQ experience.

Allowed html: a,b,br,blockquote,i,li,pre,u,ul,p

Community comments

  • error

    by haoxiang zhang,

    Your message is awaiting moderation. Thank you for participating in the discussion.

    Select[:column1, :column2].from[:table1, :table2].where do
    equal, table2.table1_id

    it is should be use {} instend of do ... end

    because of do...end will be send to Select method , not where.

  • Re: error

    by haoxiang zhang,

    Your message is awaiting moderation. Thank you for participating in the discussion.

    sorry, it is my fault.

Allowed html: a,b,br,blockquote,i,li,pre,u,ul,p

Allowed html: a,b,br,blockquote,i,li,pre,u,ul,p


Is your profile up-to-date? Please take a moment to review and update.

Note: If updating/changing your email, a validation request will be sent

Company name:
Company role:
Company size:
You will be sent an email to validate the new email address. This pop-up will close itself in a few moments.