Information on Hosting Ruby.Console?

I’m working on a project where I would like to host the IronRuby
console, and I’m getting some stack overflow exceptions. I’ve met the
end of my own knowledge, so I’m wondering if there is more information
available anywhere about doing something like this?

I was just modifying my copy of the Ruby.Console project in the
IronRuby source, but I would really like to break this into a separate
project. I started with a blank console app, and straight code copy
over, and it builds, and even starts, but anything typed into the
console causes the exception. I thought it might have been because I
had targeted the wrong .Net version, but I fixed that.

Any ideas?

-Josh

Can you provide more details? Where did it stack overflow?

Tomas

Tomas,

Thanks for your reply. Information inline.

On Sat, Aug 9, 2008 at 3:37 PM, Tomas M.
[email protected] wrote:

Can you provide more details? Where did it stack overflow?

The exact exception is:

“An unhandled exception of type ‘System.StackOverflowException’
occurred in mscorlib.dll”

The debugger points to line line 53 in matchmaker.cs:

            if (method != null) {

-this line–> method = method.MakeGenericMethod(args);
return (T)(object)Delegate.CreateDelegate(target,
this, method);
}

The specific message is:

“Cannot evaluate expression because the current thread is in a stack
overflow state.”

I thought it may have been a permissions issue, because the only way I
could get IronRuby to compile was by running as Administrator, but
this did not fix the problem either.

Including IronLibrary.Libraries.dll into your project will make it work.
And you should probably file a bug on RubyForge – we should give a more
reasonable error message when this module is missing instead of
overflowing the stack.

Could you sent full stack trace and the command you are executing on the
command line?

Tomas

Curt,

You rock my socks off. Why didn’t I catch that! Thanks for the tip,
and I’ve entered the bug report at RubyForge.

Josh

On Tue, Aug 12, 2008 at 12:14 PM, Curt H. [email protected]
wrote:

Including IronLibrary.Libraries.dll into your project will make it work. And you should probably file a bug on RubyForge – we should give a more reasonable error message when this module is missing instead of overflowing the stack.