Tomas''s message below seems to reflect what I''ve been thinking lately. Does anyone else think that in many cases porting C libraries to Ruby or even reusing ports from the Rubinius project would be beneficial to getting more libraries running on IronRuby? I''m supposing that IR performance will continue to improve, and I like the idea of contributing to more than one project (or reusing someone else''s work). Is that a good idea? Should we instead wait for FFI on IR? Or is all of this a case-by-case basis approach? I have nothing concrete in mind, atm, I''m just wondering "out loud." Cheers! Ryan Riley Email: ryan.riley at panesofglass.org LinkedIn: http://www.linkedin.com/in/ryanriley Blog: http://wizardsofsmart.net/ Twitter: @panesofglass Website: http://panesofglass.org/ On Fri, Nov 27, 2009 at 4:46 PM, Tomas Matousek < Tomas.Matousek at microsoft.com> wrote:> BTW: Since parts of the OpenSSL library are already written in Ruby (see > ruby-1.8.6p368\lib\ruby\1.8\openssl directory) it might be easier to write > the rest in Ruby as well. With calls to .NET implementation of the > cryptographic algorithms, of course. > If you chose to go that way you can add the scripts to > Merlin\Main\Languages\Ruby\Libs. > > Tomas > > -----Original Message----- > From: ironruby-core-bounces at rubyforge.org [mailto: > ironruby-core-bounces at rubyforge.org] On Behalf Of Tomas Matousek > Sent: Friday, November 27, 2009 2:38 PM > To: ironruby-core at rubyforge.org > Subject: Re: [Ironruby-core] handling ruby types and CallSiteStorage in std > library > > It depends whether the method is supposed to invoke Digest''s methods > dynamically or not. Does pkcs5_keyivgen method accept any Ruby object that > implements the methods pkcs5_keyivgen calls? Or does it need to be an > instance of Digest class? > If the former is true than you need to use "object" as the parameter type > and use dynamic call sites to invoke those methods. An example of such > dynamic behavior would be MutableStringOps.Compare. If the latter is true > you can just type the parameter to Digest CLR type and call its methods > directly. > > Tomas > > -----Original Message----- > From: ironruby-core-bounces at rubyforge.org [mailto: > ironruby-core-bounces at rubyforge.org] On Behalf Of Dylan McClung > Sent: Friday, November 27, 2009 9:34 AM > To: ironruby-core at rubyforge.org > Subject: [Ironruby-core] handling ruby types and CallSiteStorage in std > library > > I''m working on adding code to the OpenSSL extension of the standard library > and I need to understand the design for invoking and typing Ruby code. I > read the ''Modifying the sources'' github page and it mentions using > CallSiteStorage to call into Ruby code. > > Specifically, the Cipher ruby class has a dependency on the Digest ruby > classes for the pkcs5_keyivgen method. An optional parameter for this > method is an instance of the Ruby class Digest::Base. How would the type > look, maybe Digest.Digest.Base digest/*optional*/? Or would it be an object > and I''d also need to pass in CallSiteStorage to call methods on the object? > > An example in the standard library of such behavior would be much > appreciated, thanks for any help. > -- > Posted via http://www.ruby-forum.com/. > _______________________________________________ > Ironruby-core mailing list > Ironruby-core at rubyforge.org > http://rubyforge.org/mailman/listinfo/ironruby-core > > _______________________________________________ > Ironruby-core mailing list > Ironruby-core at rubyforge.org > http://rubyforge.org/mailman/listinfo/ironruby-core > > _______________________________________________ > Ironruby-core mailing list > Ironruby-core at rubyforge.org > http://rubyforge.org/mailman/listinfo/ironruby-core >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://rubyforge.org/pipermail/ironruby-core/attachments/20091217/c9d7fbed/attachment.html>
For the rest of our ~10% missing Ruby built-in/library support, using code from Rubinius could possibly make more things work. I?d try this out for a library you care about that isn?t implemented, see if you can get all the specs passing for that, and report back. =) However, are you referring to ?C-library ports to Ruby? that are outside the Ruby stdlib (as in, 3rd party libs, gems, etc)? I don?t know of many of those existing, but probably because I haven?t been looking, but again if they do exist their doesn?t seem like anything wrong with trying to get them working on IronRuby for more 3rd party library support. The only issues I see is if they somehow use Rubinius only features. Another thing to be aware of is licensing; the IronRuby codebase is partitioned into three licenses, based on where we got the code from: Ms-Pl, Ruby license, and Creative Commons. If the intention is to commit these Ruby libraries into IronRuby to fill out our support, then we just need to be mindful of what license the incoming code. ~Jimmy From: ironruby-core-bounces at rubyforge.org [mailto:ironruby-core-bounces at rubyforge.org] On Behalf Of Ryan Riley Sent: Thursday, December 17, 2009 9:00 AM To: ironruby-core at rubyforge.org Subject: [Ironruby-core] Ruby Libraries ==> IronRuby Tomas''s message below seems to reflect what I''ve been thinking lately. Does anyone else think that in many cases porting C libraries to Ruby or even reusing ports from the Rubinius project would be beneficial to getting more libraries running on IronRuby? I''m supposing that IR performance will continue to improve, and I like the idea of contributing to more than one project (or reusing someone else''s work). Is that a good idea? Should we instead wait for FFI on IR? Or is all of this a case-by-case basis approach? I have nothing concrete in mind, atm, I''m just wondering "out loud." Cheers! Ryan Riley Email: ryan.riley at panesofglass.org<mailto:ryan.riley at panesofglass.org> LinkedIn: http://www.linkedin.com/in/ryanriley Blog: http://wizardsofsmart.net/ Twitter: @panesofglass Website: http://panesofglass.org/ On Fri, Nov 27, 2009 at 4:46 PM, Tomas Matousek <Tomas.Matousek at microsoft.com<mailto:Tomas.Matousek at microsoft.com>> wrote: BTW: Since parts of the OpenSSL library are already written in Ruby (see ruby-1.8.6p368\lib\ruby\1.8\openssl directory) it might be easier to write the rest in Ruby as well. With calls to .NET implementation of the cryptographic algorithms, of course. If you chose to go that way you can add the scripts to Merlin\Main\Languages\Ruby\Libs. Tomas -----Original Message----- From: ironruby-core-bounces at rubyforge.org<mailto:ironruby-core-bounces at rubyforge.org> [mailto:ironruby-core-bounces at rubyforge.org<mailto:ironruby-core-bounces at rubyforge.org>] On Behalf Of Tomas Matousek Sent: Friday, November 27, 2009 2:38 PM To: ironruby-core at rubyforge.org<mailto:ironruby-core at rubyforge.org> Subject: Re: [Ironruby-core] handling ruby types and CallSiteStorage in std library It depends whether the method is supposed to invoke Digest''s methods dynamically or not. Does pkcs5_keyivgen method accept any Ruby object that implements the methods pkcs5_keyivgen calls? Or does it need to be an instance of Digest class? If the former is true than you need to use "object" as the parameter type and use dynamic call sites to invoke those methods. An example of such dynamic behavior would be MutableStringOps.Compare. If the latter is true you can just type the parameter to Digest CLR type and call its methods directly. Tomas -----Original Message----- From: ironruby-core-bounces at rubyforge.org<mailto:ironruby-core-bounces at rubyforge.org> [mailto:ironruby-core-bounces at rubyforge.org<mailto:ironruby-core-bounces at rubyforge.org>] On Behalf Of Dylan McClung Sent: Friday, November 27, 2009 9:34 AM To: ironruby-core at rubyforge.org<mailto:ironruby-core at rubyforge.org> Subject: [Ironruby-core] handling ruby types and CallSiteStorage in std library I''m working on adding code to the OpenSSL extension of the standard library and I need to understand the design for invoking and typing Ruby code. I read the ''Modifying the sources'' github page and it mentions using CallSiteStorage to call into Ruby code. Specifically, the Cipher ruby class has a dependency on the Digest ruby classes for the pkcs5_keyivgen method. An optional parameter for this method is an instance of the Ruby class Digest::Base. How would the type look, maybe Digest.Digest.Base digest/*optional*/? Or would it be an object and I''d also need to pass in CallSiteStorage to call methods on the object? An example in the standard library of such behavior would be much appreciated, thanks for any help. -- Posted via http://www.ruby-forum.com/. _______________________________________________ Ironruby-core mailing list Ironruby-core at rubyforge.org<mailto:Ironruby-core at rubyforge.org> http://rubyforge.org/mailman/listinfo/ironruby-core _______________________________________________ Ironruby-core mailing list Ironruby-core at rubyforge.org<mailto:Ironruby-core at rubyforge.org> http://rubyforge.org/mailman/listinfo/ironruby-core _______________________________________________ Ironruby-core mailing list Ironruby-core at rubyforge.org<mailto:Ironruby-core at rubyforge.org> http://rubyforge.org/mailman/listinfo/ironruby-core -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://rubyforge.org/pipermail/ironruby-core/attachments/20091217/09e911ad/attachment-0001.html>
Correction: replace ?Creative Commons? with CPL: http://www.opensource.org/licenses/cpl1.0.php From: ironruby-core-bounces at rubyforge.org [mailto:ironruby-core-bounces at rubyforge.org] On Behalf Of Jimmy Schementi Sent: Thursday, December 17, 2009 10:55 AM To: ironruby-core at rubyforge.org Subject: Re: [Ironruby-core] Ruby Libraries ==> IronRuby For the rest of our ~10% missing Ruby built-in/library support, using code from Rubinius could possibly make more things work. I?d try this out for a library you care about that isn?t implemented, see if you can get all the specs passing for that, and report back. =) However, are you referring to ?C-library ports to Ruby? that are outside the Ruby stdlib (as in, 3rd party libs, gems, etc)? I don?t know of many of those existing, but probably because I haven?t been looking, but again if they do exist their doesn?t seem like anything wrong with trying to get them working on IronRuby for more 3rd party library support. The only issues I see is if they somehow use Rubinius only features. Another thing to be aware of is licensing; the IronRuby codebase is partitioned into three licenses, based on where we got the code from: Ms-Pl, Ruby license, and Creative Commons. If the intention is to commit these Ruby libraries into IronRuby to fill out our support, then we just need to be mindful of what license the incoming code. ~Jimmy From: ironruby-core-bounces at rubyforge.org [mailto:ironruby-core-bounces at rubyforge.org] On Behalf Of Ryan Riley Sent: Thursday, December 17, 2009 9:00 AM To: ironruby-core at rubyforge.org Subject: [Ironruby-core] Ruby Libraries ==> IronRuby Tomas''s message below seems to reflect what I''ve been thinking lately. Does anyone else think that in many cases porting C libraries to Ruby or even reusing ports from the Rubinius project would be beneficial to getting more libraries running on IronRuby? I''m supposing that IR performance will continue to improve, and I like the idea of contributing to more than one project (or reusing someone else''s work). Is that a good idea? Should we instead wait for FFI on IR? Or is all of this a case-by-case basis approach? I have nothing concrete in mind, atm, I''m just wondering "out loud." Cheers! Ryan Riley Email: ryan.riley at panesofglass.org<mailto:ryan.riley at panesofglass.org> LinkedIn: http://www.linkedin.com/in/ryanriley Blog: http://wizardsofsmart.net/ Twitter: @panesofglass Website: http://panesofglass.org/ On Fri, Nov 27, 2009 at 4:46 PM, Tomas Matousek <Tomas.Matousek at microsoft.com<mailto:Tomas.Matousek at microsoft.com>> wrote: BTW: Since parts of the OpenSSL library are already written in Ruby (see ruby-1.8.6p368\lib\ruby\1.8\openssl directory) it might be easier to write the rest in Ruby as well. With calls to .NET implementation of the cryptographic algorithms, of course. If you chose to go that way you can add the scripts to Merlin\Main\Languages\Ruby\Libs. Tomas -----Original Message----- From: ironruby-core-bounces at rubyforge.org<mailto:ironruby-core-bounces at rubyforge.org> [mailto:ironruby-core-bounces at rubyforge.org<mailto:ironruby-core-bounces at rubyforge.org>] On Behalf Of Tomas Matousek Sent: Friday, November 27, 2009 2:38 PM To: ironruby-core at rubyforge.org<mailto:ironruby-core at rubyforge.org> Subject: Re: [Ironruby-core] handling ruby types and CallSiteStorage in std library It depends whether the method is supposed to invoke Digest''s methods dynamically or not. Does pkcs5_keyivgen method accept any Ruby object that implements the methods pkcs5_keyivgen calls? Or does it need to be an instance of Digest class? If the former is true than you need to use "object" as the parameter type and use dynamic call sites to invoke those methods. An example of such dynamic behavior would be MutableStringOps.Compare. If the latter is true you can just type the parameter to Digest CLR type and call its methods directly. Tomas -----Original Message----- From: ironruby-core-bounces at rubyforge.org<mailto:ironruby-core-bounces at rubyforge.org> [mailto:ironruby-core-bounces at rubyforge.org<mailto:ironruby-core-bounces at rubyforge.org>] On Behalf Of Dylan McClung Sent: Friday, November 27, 2009 9:34 AM To: ironruby-core at rubyforge.org<mailto:ironruby-core at rubyforge.org> Subject: [Ironruby-core] handling ruby types and CallSiteStorage in std library I''m working on adding code to the OpenSSL extension of the standard library and I need to understand the design for invoking and typing Ruby code. I read the ''Modifying the sources'' github page and it mentions using CallSiteStorage to call into Ruby code. Specifically, the Cipher ruby class has a dependency on the Digest ruby classes for the pkcs5_keyivgen method. An optional parameter for this method is an instance of the Ruby class Digest::Base. How would the type look, maybe Digest.Digest.Base digest/*optional*/? Or would it be an object and I''d also need to pass in CallSiteStorage to call methods on the object? An example in the standard library of such behavior would be much appreciated, thanks for any help. -- Posted via http://www.ruby-forum.com/. _______________________________________________ Ironruby-core mailing list Ironruby-core at rubyforge.org<mailto:Ironruby-core at rubyforge.org> http://rubyforge.org/mailman/listinfo/ironruby-core _______________________________________________ Ironruby-core mailing list Ironruby-core at rubyforge.org<mailto:Ironruby-core at rubyforge.org> http://rubyforge.org/mailman/listinfo/ironruby-core _______________________________________________ Ironruby-core mailing list Ironruby-core at rubyforge.org<mailto:Ironruby-core at rubyforge.org> http://rubyforge.org/mailman/listinfo/ironruby-core -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://rubyforge.org/pipermail/ironruby-core/attachments/20091217/71137a52/attachment-0001.html>
About OpenSSL, IronPython already supports ssl (http://www.python.org/doc/2.6/library/ssl.html) and that code could be used as a starting point. Not sure how much overlap there is between the two versions of SSL. Just updating the mailing list after hearing about the IronPython version recently... ________________________________ From: ironruby-core-bounces at rubyforge.org [ironruby-core-bounces at rubyforge.org] on behalf of Ryan Riley [ryan.riley at panesofglass.org] Sent: Thursday, December 17, 2009 8:59 AM To: ironruby-core at rubyforge.org Subject: [Ironruby-core] Ruby Libraries ==> IronRuby Tomas''s message below seems to reflect what I''ve been thinking lately. Does anyone else think that in many cases porting C libraries to Ruby or even reusing ports from the Rubinius project would be beneficial to getting more libraries running on IronRuby? I''m supposing that IR performance will continue to improve, and I like the idea of contributing to more than one project (or reusing someone else''s work). Is that a good idea? Should we instead wait for FFI on IR? Or is all of this a case-by-case basis approach? I have nothing concrete in mind, atm, I''m just wondering "out loud." Cheers! Ryan Riley Email: ryan.riley at panesofglass.org<mailto:ryan.riley at panesofglass.org> LinkedIn: http://www.linkedin.com/in/ryanriley Blog: http://wizardsofsmart.net/ Twitter: @panesofglass Website: http://panesofglass.org/ On Fri, Nov 27, 2009 at 4:46 PM, Tomas Matousek <Tomas.Matousek at microsoft.com<mailto:Tomas.Matousek at microsoft.com>> wrote: BTW: Since parts of the OpenSSL library are already written in Ruby (see ruby-1.8.6p368\lib\ruby\1.8\openssl directory) it might be easier to write the rest in Ruby as well. With calls to .NET implementation of the cryptographic algorithms, of course. If you chose to go that way you can add the scripts to Merlin\Main\Languages\Ruby\Libs. Tomas -----Original Message----- From: ironruby-core-bounces at rubyforge.org<mailto:ironruby-core-bounces at rubyforge.org> [mailto:ironruby-core-bounces at rubyforge.org<mailto:ironruby-core-bounces at rubyforge.org>] On Behalf Of Tomas Matousek Sent: Friday, November 27, 2009 2:38 PM To: ironruby-core at rubyforge.org<mailto:ironruby-core at rubyforge.org> Subject: Re: [Ironruby-core] handling ruby types and CallSiteStorage in std library It depends whether the method is supposed to invoke Digest''s methods dynamically or not. Does pkcs5_keyivgen method accept any Ruby object that implements the methods pkcs5_keyivgen calls? Or does it need to be an instance of Digest class? If the former is true than you need to use "object" as the parameter type and use dynamic call sites to invoke those methods. An example of such dynamic behavior would be MutableStringOps.Compare. If the latter is true you can just type the parameter to Digest CLR type and call its methods directly. Tomas -----Original Message----- From: ironruby-core-bounces at rubyforge.org<mailto:ironruby-core-bounces at rubyforge.org> [mailto:ironruby-core-bounces at rubyforge.org<mailto:ironruby-core-bounces at rubyforge.org>] On Behalf Of Dylan McClung Sent: Friday, November 27, 2009 9:34 AM To: ironruby-core at rubyforge.org<mailto:ironruby-core at rubyforge.org> Subject: [Ironruby-core] handling ruby types and CallSiteStorage in std library I''m working on adding code to the OpenSSL extension of the standard library and I need to understand the design for invoking and typing Ruby code. I read the ''Modifying the sources'' github page and it mentions using CallSiteStorage to call into Ruby code. Specifically, the Cipher ruby class has a dependency on the Digest ruby classes for the pkcs5_keyivgen method. An optional parameter for this method is an instance of the Ruby class Digest::Base. How would the type look, maybe Digest.Digest.Base digest/*optional*/? Or would it be an object and I''d also need to pass in CallSiteStorage to call methods on the object? An example in the standard library of such behavior would be much appreciated, thanks for any help. -- Posted via http://www.ruby-forum.com/. _______________________________________________ Ironruby-core mailing list Ironruby-core at rubyforge.org<mailto:Ironruby-core at rubyforge.org> http://rubyforge.org/mailman/listinfo/ironruby-core _______________________________________________ Ironruby-core mailing list Ironruby-core at rubyforge.org<mailto:Ironruby-core at rubyforge.org> http://rubyforge.org/mailman/listinfo/ironruby-core _______________________________________________ Ironruby-core mailing list Ironruby-core at rubyforge.org<mailto:Ironruby-core at rubyforge.org> http://rubyforge.org/mailman/listinfo/ironruby-core -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://rubyforge.org/pipermail/ironruby-core/attachments/20100207/97e3fb07/attachment-0001.html>