, 2010 9:06 AM
To: ironruby-core@rubyforge.org
Subject: Re: [Ironruby-core] Calling a C# method with a byref parameter
Generic type inference should work like it does in C#. I’ll get some more tests
in there and get Jimmy to update the docs.
JD
From: ironruby-core-boun...@rubyforge.org
-core@rubyforge.org
Subject: Re: [Ironruby-core] Calling a C# method with a byref parameter
On what types will IR be able to infer the types? Is that documented on the
site and I just didn't see it?
Ryan Riley
On Thu, Feb 11, 2010 at 9:55 AM, Jim Deville
mailto:jdevi...@microsoft.com>>
; *From:* ironruby-core-boun...@rubyforge.org [mailto:
>> ironruby-core-boun...@rubyforge.org] *On Behalf Of *Shay Friedman
>> *Sent:* Thursday, February 11, 2010 6:53 AM
>> *To:* ironruby-core@rubyforge.org
>> *Subject:* Re: [Ironruby-core] Calling a C# method with
.org
> *Subject:* Re: [Ironruby-core] Calling a C# method with a byref parameter
>
>
>
> You should call generic methods a bit differently.
>
>
>
> The next code works:
>
> ret_val = c.method(:do_something_else).of(String).call(str)
>
>
>
> Shay.
>
ruary 11, 2010 6:53 AM
To: ironruby-core@rubyforge.org
Subject: Re: [Ironruby-core] Calling a C# method with a byref parameter
You should call generic methods a bit differently.
The next code works:
ret_val = c.method(:do_something_else).of(String).call(str)
You should call generic methods a bit differently.
The next code works:
ret_val = c.method(:do_something_else).of(String).call(str)
Shay.
Shay Friedman | .NET Technologies Expert | Author of IronRuby Unleashed |
Sela Technology Center
Blog:
Thanks Shay.
OK your code works. But my trouble seems to come in with the Generic
method.
When I do:
public class Class1
{
public string DoSomething(ref string test)
{
test = test + "tamtamtam";
return "return value";
}
public string
It returns another return value with the new ref value.
For example, if you have the next c# class:
public class Class1
{
public string DoSomething(ref string test)
{
test = test + "tamtamtam";
return "return value";
}
}
This is the IronRuby code you can write to use
Hi Everyone,
I'm trying to write a IronRuby script that interops with a a .NET assembly
written in C#.
It has a class that derives from a base class in the .NET assembly. One of
the base class protected methods looks like this:
protected void OnNotifyPropertyChanged(string name, ref T localmembe