BT

Facilitating the Spread of Knowledge and Innovation in Professional Software Development

Write for InfoQ

Topics

Choose your language

InfoQ Homepage News Ruby.NET 0.8 release

Ruby.NET 0.8 release

Bookmarks
Ruby implementations are a dime a dozen nowadays. There are already two implementations of Ruby for the JVM (JRuby and XRuby), and .NET is catching up as well. IronRuby has caused a lot of buzz in the past month, but until it's released in late July 2007, it's not known just how complete it'll be.

Gardens Point Ruby.NET compiler, from a team around Dr. Wayne Kelly and Prof. John Gough at the Queensland University of Technology, on the other hand, has been available since June 2006. It works by compiling Ruby code to Microsoft Intermediate Language (MSIL, the instruction set of the .NET CLR ), which is then executed by the CLR.

There's an interesting relationship between IronRuby and Ruby.NET. John Lam, developer of IronRuby, mentions that IronRuby actually uses parts of Ruby.NET:
We licensed the Ruby.net codebase earlier this year, and we are using the scanner and parser from Ruby.net in IronRuby today. This helped us bootstrap our efforts, and we know that we have acquired a good scanner and parser that is already highly compliant with MRI[.]
A compliant Ruby parser is a big part of a Ruby implementation, and using Ruby.NET's parser surely saves the IronRuby team a lot of work.

Ruby.NET's new 0.8 release adds important functionality:
Since the last release we have added support for interoperability with other .NET languages, so that components developed using other .NET languages can conveniently use classes implemented using Ruby.NET and vice versa.
An example for this is shown with a Ruby class that's used in C# code. The Ruby class:
class Person
 def init(name, age)
 @name = name
  @age = age
 end
 def print()
 puts "#{@name} is #{@age}"
 end
end

Using this from C#:
Person bruce = new Person();
bruce.init("Bruce", 42);
bruce.print();

This works in the other direction (Ruby using .NET classes) too. Another interesting remark in the 0.8 release notes:
We will soon be moving to a more traditional open source model of community contribution to our code base and will be calling for volunteer developers. If anyone has any experience in managing that kind of process, we'd be interested in your input.
In light of recent doubts about IronRuby, and the the fact that over the past year, many Ruby runtime developers have been hired to work on their projects (JRuby, XRuby, Rubinius, IronRuby), .NET Open Source developers with an interest in Ruby might want to look into this.

Rate this Article

Adoption
Style

BT