[Ironruby-core] Support For Referencing Ruby Libs As Embedded Resources?

M. David Peterson m.david at xmlhacker.com
Fri Feb 8 21:16:52 EST 2008

On Fri, 08 Feb 2008 19:09:25 -0700, John Messerly <jomes at microsoft.com>  

> Right, but if you have a DLL already, you can just host IronRuby from C#  
> and feed it Ruby code however you want to.

True.  So would that then be the prefered way to go about providing  

> I guess I'd be hesitant to change the meaning of "require". The way we  
> have it now (require 'mscorlib') is nice because it's not changing the  
> behavior. If you really wanted to you could write mscorlib.rb and run  
> your code on another Ruby implementation.

Oh, I'm not suggesting changing the meaning, just adding a handler for the  
'res' protocol that would locate the source file via an assembly rather  
than the file system.  To me, anyway, I don't see any difference between  

require 'C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\System.dll'

... means and what,

require 'res://assemblyname.dll/foo/bar'

... means, at least in regards to the fact that they both represent  
references to external libraries.


M. David Peterson
Co-Founder & Chief Architect, 3rd&Urban, LLC
Email: m.david at 3rdandUrban.com | m.david at amp.fm
Mobile: (206) 418-9027
http://3rdandUrban.com | http://amp.fm |  

More information about the Ironruby-core mailing list