[Ironruby-core] Initializing external Ruby libraries

John Messerly jomes at microsoft.com
Wed Feb 13 21:00:28 EST 2008

Michael Letterle:

> Yes, my only point is that the way it works today a .NET class becomes
> a Ruby class and a .NET method becomes a Ruby method.  Nothing is
> stopping one from writing a .NET assembly so that it "feels" like Ruby
> when it's compiled.
> That said, I can see the advantage of being able to use the RubyClass
> and RubyMethod attributes outside of that..
> Is the performance between this and utilizing an Initializer that
> great?

Sorry, I misunderstood. I thought you were suggesting writing the library as a .rb file & using .NET interop features to call into the .NET code.

Yeah, you couldn't just write it in C# because we need the initializer to give proper Ruby method names & public/protected/private/instance/singleton metadata. It's also a performance win because we don't need to use reflection to pull out the metadata at runtime.

- John

More information about the Ironruby-core mailing list