Ruby.NET
I had blogged earlier about Gardens Point Ruby.NET. After I read Don Box writing about it, I decided to give it a try.
I tried compiling some Ruby code. I failed to get the retry code to run. It kept giving "Unable to cast object of type 'Ruby.Object' to type 'Ruby.Class'" error.
I tried to compile other code like the webserver and line number and also closure code. Most of them compiled and worked. However wherever I had references to ruby library classes it failed to run due to lack of support. Since any piece of code that accomplishes something significant is bound to use some of these libraries it'll be difficult to truly check out Ruby.NET until it supports these libraries. However if calling .NET BCL libraries becomes possible it'll open a Pandora's box!!!
Overall I was fairly impressed with it. Especially a look into the generated exe using Reflector made my brain hurt. I'm sure it'd have been immensely difficult to fit a dynamic language like Ruby into a static-typed CLR. Facts like ruby methods can be dynamically added and removed from classes and that a class can be arbitrarily spread across files with no inter-connection between them complicates the whole thing.
The ability to call .NET framework from the Ruby code should've been enabled. With that the true power of Ruby.NET would have come out. Or did I fail to figure out how that can be done??
Comments
- Anonymous
August 07, 2006
Check out JRuby. Seems to be a little bit more mature than Ruby.NET - Anonymous
August 07, 2006
Yes JRuby is a lot more mature. However there had been other Ruby implementations for .NET before. This is the true compiled Ruby. Agreed its in early stages but once we get the interop done it'll be a programmers delight :)
Ruby calling into all our extensive .NET class libraries is like a dream come true. - Anonymous
August 07, 2006
Have you not been looking at John Lam's RubyCLR?
http://technorati.com/search/RubyCLR - Anonymous
August 07, 2006
It relatively easy to interpret dynamic languages, compiling them for the CLR is another story. Have a look at LSharp for example. I gave making a compiler a go, but gave up very soon! - Anonymous
August 24, 2006
The comment has been removed