Re: [Ironruby-core] Error when running Cucumber examples with IronRuby

2009-04-02 Thread Tomas Matousek
Let's file a bug. We have more control flow issues to be fixed. I'll fix them all at once. Thanks for investigation, Tomas -Original Message- From: ironruby-core-boun...@rubyforge.org [mailto:ironruby-core-boun...@rubyforge.org] On Behalf Of Shri Borde Sent: Wednesday, April 01, 2009 10

Re: [Ironruby-core] agdlr test w/ ruby string

2009-04-02 Thread Jb Evain
On 4/1/09, Jb Evain wrote: > Is IronRuby doing some conversion here, or is it Silverlight doing > interesting things when marshalling the value? Alright, so for the curious, after an update, the string comparison works ok on Moonlight. The issue is indeed marshaling in Silverlight, which decid

Re: [Ironruby-core] defined?(xxx) behaves differently when called from Silverlight

2009-04-02 Thread Thibaut Barrère
Hi, I believe I need to give you more context about what I'm doing. In Magic (see here in particular) I currently have a single file providing support for WPF, Silverlight and Windows Forms. I use define

Re: [Ironruby-core] defined?(xxx) behaves differently when called from Silverlight

2009-04-02 Thread Jimmy Schementi
The folder SL is installed into is the version; if you're using SL2 it should be C:\Program Files\Microsoft Silverlight\2.0.40115.0\. SL3 Beta is C:\Program Files\Microsoft Silverlight\3.0.40307.0\. http://jimmy.schementi.com/silverlight/repro-defined.zip Unzip that and double-click on the inde

[Ironruby-core] How to instanciate a System::String[] from IronRuby?

2009-04-02 Thread Thibaut Barrère
Hi, while trying to call some C# code from IronRuby, I get this: my_csharp_class_instance.call(%w(some array)) :0: can't convert Array into System::String[] (TypeError) Is there some easy way to construct an array of System::String ? Or a conversion ? cheers, -- Thibaut __

Re: [Ironruby-core] How to instanciate a System::String[] from IronRuby?

2009-04-02 Thread Curt Hagenlocher
I don't know if it's the easiest way, but this should work as a conversion: x = ['a', 'b', 'c'] System::Array[System::String].new(x.map { |s| s.to_s.to_clr_string }) (Obviously, if you know that the elements are already Ruby strings, you can omit the "to_s".) From: ironruby-core-boun...@rubyfor

Re: [Ironruby-core] How to instanciate a System::String[] from IronRuby?

2009-04-02 Thread Michael Letterle
class Array def to_clr_arr arr = System::Array.CreateInstance self[0].class.to_clr_type, System::Int32.pase(self.length.to_s) self.each_with_index { |r, i| arr[i] = r } return arr end end my_csharp_class_instance.call(%w(some array).map{|x| x.to_clr_string}.to_c

Re: [Ironruby-core] How to instanciate a System::String[] from IronRuby?

2009-04-02 Thread Jim Deville
Jimmy and I have discussed a to_clr_array(type) where type defaults to Object, but nothing like that exists yet. JD From: ironruby-core-boun...@rubyforge.org [ironruby-core-boun...@rubyforge.org] on behalf of Curt Hagenlocher [cu...@microsoft.com] Sent: Thursday

[Ironruby-core] error --> undefined method 'length' for nil:NilClass

2009-04-02 Thread Robert Johnson
I just updated my local repo from gitHub and when I run rake compile I see the following error: C:\Users\Robert\bob-code-repo\ironruby_working\Merlin\Main\Languag

Re: [Ironruby-core] error --> undefined method 'length' for nil:NilClass

2009-04-02 Thread Jim Deville
It's probably related to Merlin\External moving to Merlin\External.LCA_RESTRICTED. I'll figure it out and push out a new revision in a few hours. JD From: ironruby-core-boun...@rubyforge.org [mailto:ironruby-core-boun...@rubyforge.org] On Behalf Of Robert Johnson Sent: Thursday, April 02, 2009

Re: [Ironruby-core] How to instanciate a System::String[] from IronRuby?

2009-04-02 Thread Tomas Matousek
This is the right way: x = ['a', 'b', 'c'] System::Array[System::String].new(x.map { |s| s.to_s.to_clr_string }) This would simplify to x = ['a', 'b', 'c'] System::Array[System::String].new(x) As soon as we implement implicit conversions here. Tomas From: ironruby-core-boun...@rubyforge.org

[Ironruby-core] FYI review - Jirapong's fixes for GzipFile#finish

2009-04-02 Thread Shri Borde
FYI review only... This is Jirapong's change. A big thanks to Jirapong for his first contribution to IronRuby! Looking forward to many more! I have pushed it to my fork. The individual commits are shown below, but there will be a bit of noise as Jirapong bounced questions off me. I should proba

Re: [Ironruby-core] FYI review - Jirapong's fixes for GzipFile#finish

2009-04-02 Thread Jim Deville
The debugger method shouldn't be in spec_helper.rb. It's a IronRuby specific method and that file is a MSpec file. Also, it's missing an end. Other than that, test looks good. JD From: Shri Borde Sent: Thursday, April 02, 2009 12:08 PM To: IronRuby External Code Reviewers Cc: ironruby-core@ruby

[Ironruby-core] Proposal: Moving IronRuby bugs to CodePlex

2009-04-02 Thread Jimmy Schementi
(I originally planned on sending this yesterday, but I waited until today to remove the "April Fools" possibility =P) I'd like to propose moving IronRuby's bugs off of RubyForge. CodePlex looks like the best option, mainly due to the voting feature for bugs. Here are some possible options for de

Re: [Ironruby-core] How to instanciate a System::String[] from IronRuby?

2009-04-02 Thread Thibaut Barrère
Hi, thanks for the feedback - I'll give these a go. cheers -- Thibaut ___ Ironruby-core mailing list Ironruby-core@rubyforge.org http://rubyforge.org/mailman/listinfo/ironruby-core

Re: [Ironruby-core] defined?(xxx) behaves differently when called from Silverlight

2009-04-02 Thread Thibaut Barrère
Hey, I finally removed all the bits of Silverlight (/Library/Internet Plug-Ins/Silverlight* , /Library/Receipts/Silverlight*.pkg) and reinstalled SL2. It now works as expected. I didn't find some way to understand what really happened, but the issue is solved anyway. thanks for your support, --

Re: [Ironruby-core] defined?(xxx) behaves differently when called from Silverlight

2009-04-02 Thread Jimmy Schementi
Ah, you were on a Mac. Let me know if it happens again. > -Original Message- > From: ironruby-core-boun...@rubyforge.org [mailto:ironruby-core- > boun...@rubyforge.org] On Behalf Of Thibaut Barrère > Sent: Thursday, April 02, 2009 4:31 PM > To: ironruby-core@rubyforge.org > Subject: Re: [I

Re: [Ironruby-core] defined?(xxx) behaves differently when called from Silverlight

2009-04-02 Thread Thibaut Barrère
> > The folder SL is installed into is the version; if you’re using SL2 it > should be C:\Program Files\Microsoft Silverlight\2.0.40115.0\. SL3 Beta is > C:\Program Files\Microsoft Silverlight\3.0.40307.0\. > I'm testing this from my Mac. I'll be searching for the files using find. > > > http://ji

Re: [Ironruby-core] defined?(xxx) behaves differently when called from Silverlight

2009-04-02 Thread Jimmy Schementi
From: ironruby-core-boun...@rubyforge.org [mailto:ironruby-core-boun...@rubyforge.org] On Behalf Of Thibaut Barrère Sent: Thursday, April 02, 2009 3:44 PM To: ironruby-core@rubyforge.org Subject: Re: [Ironruby-core] defined?(xxx) behaves differently when called from Silverlight The folder SL is

Re: [Ironruby-core] defined?(xxx) behaves differently when called from Silverlight

2009-04-02 Thread Jimmy Schementi
Woops, hit send too soon. I just tested it out on a Mac in FF3 and Safari3, and nothing blew up and the console rendered fine. You're future mail said things work, so I guess I'm just confirming that your prior installation was all-sorts-of-crazy. Also, Chiron on the Mac wouldn't cause this, as