Ruby Future Roundup: Ruby 1.9.0-5 Released, JRuby Skips 1.8.7, Procs#=== For Case Testing

| by Mirko Stocker Follow 0 Followers on Oct 08, 2008. Estimated reading time: 1 minute |

A note to our readers: You asked so we have developed a set of features that allow you to reduce the noise: you can get email and web notifications for topics you are interested in. Learn more about our new features.

Ruby 1.9.0-5 Released

On Friday the 3rd, Ruby 1.9.0-5 was released by Yuki Sonoda, after the last delays, related to miniunit, were fixed by Ryan Davis. This release also marks the feature freeze for the upcoming version 1.9.1. (see the changelog for detailed information).

JRuby Not Going to Support 1.8.7

Marcin Mielżyński, one of the JRuby committers, proposed to drop support for Ruby 1.8.7 in JRuby:

Most 1.8.7 features that came from 1.9.1 are to make transition from 1.8 to 1.9 series easier. Majority of them is just a copy (with minor changes to match 1.8.x api), but there is a lot of tricky examples that behave differently under 1.9.x, 1.8.6 and 1.8.7 [...] it doesn't make sense to port all the behavior from 1.9.x to 1.8.7 since it would end up 1.9.x just without yarv and all the fancy syntax features (well, and encoding support of course).

Thomas Enebo and Charles Nutter agreed and added, that users should switch directly to 1.9 rather then writing code that only works in 1.8.7 (support for Ruby 1.9 in JRuby can be enabled with --1.9). Charles also posted their decision to the Ruby-core mailinglist., but no discussion has started yet.

Procs for Case Equality Testing

Ruby uses the ===-operator to compare the different cases in a case-statement. Ruby 1.9's Proc class just recently got a ===-method, basically just an alias for the call-method used to invoke the Proc. Now, this means that one can use a Proc object in a case-statement; it will get the case-argument as parameter. This trick was discovered by Aimred, who added the method themselves, before Matz integrated it into Ruby 1.9.

Dave Thomas shows an even more sophisticated application, using currying to create several Procs to check for the day of the week.

Rate this Article

Adoption Stage

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.

Tell us what you think

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

Email me replies to any of my messages in this thread

feature freeze by Roger Pack

I believe the feature freeze is still a little loose as they are still trying to finalize...basically miniunit :)

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

Email me replies to any of my messages in this thread

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

Email me replies to any of my messages in this thread

1 Discuss

Login to InfoQ to interact with what matters most to you.

Recover your password...


Follow your favorite topics and editors

Quick overview of most important highlights in the industry and on the site.


More signal, less noise

Build your own feed by choosing topics you want to read about and editors you want to hear from.


Stay up-to-date

Set up your notifications and don't miss out on content that matters to you