Ruby for .NET

A

Arich Chanachai

A few questions for the Ruby community:

1. Does anyone know of a project that is implementing Ruby on the
..NET/Mono platform?
2. Do tools exist to port Python code to Ruby and vice versa?
3. Does a Ruby compiler exist similar to the python compiler for Java
(Jython)?
4. How easy is it to interface Ruby to C/C++ class libraries?

Thanks folks!
 
J

James Edward Gray II

3. Does a Ruby compiler exist similar to the python compiler for Java
(Jython)?

Not exactly what you asked here, but perhaps you need to look into
JRuby.

Hope that helps.

James
 
R

Robert Klemme

Arich Chanachai said:
A few questions for the Ruby community:

1. Does anyone know of a project that is implementing Ruby on the
.NET/Mono platform?
2. Do tools exist to port Python code to Ruby and vice versa?

I'm not sure. There were discussions about this issue recently. Maybe
you can find a project here
http://raa.ruby-lang.org/
3. Does a Ruby compiler exist similar to the python compiler for Java
(Jython)?

Not exactly but there is Groovy - if you need the looks of Ruby and the
speed of Java. See http://groovy.codehaus.org/
4. How easy is it to interface Ruby to C/C++ class libraries?

Quite easy AFAIK. See
http://www.ruby-doc.org/docs/ProgrammingRuby/html/ext_ruby.html

Kind regards

robert
 
G

gabriele renzi

Arich Chanachai ha scritto:
A few questions for the Ruby community:

1. Does anyone know of a project that is implementing Ruby on the
.NET/Mono platform?

there is a proof of concept implementation, but nothing released.
Anyway you can use rubydotnet wich is an interesting bridge (it allows
you to use every .net library but does not compile to clr)
 
J

Jim Weirich

Not exactly but there is Groovy - if you need the looks of Ruby and the

I've seen several posts that hint that Groovy runs at Java-like speeds.
I haven't found this to be true at all. You can find one of my (very
incomplete and probably totally useless) benchmarks here:
http://onestepback.org/articles/groovy/groovyspeed.html

Don't get me wrong ... I think Groovy has a lot of promise for those
living in the JVM world. However, it is still a very young language and
has some growing to do.
 
S

Steve Kellock

To kinda/sorta/but-not-really answer question #1... check out

http://www.saltypickle.com/rubydotnet/

I got it working and hooked into .NET (both straight-up objects and
WinForms stuff). It's neat, but I wouldn't use it for anything
production related. Also, I've only tested it on XP.

Cheers...
 
R

Robert Klemme

Jim Weirich said:
I've seen several posts that hint that Groovy runs at Java-like speeds.
I haven't found this to be true at all. You can find one of my (very
incomplete and probably totally useless) benchmarks here:
http://onestepback.org/articles/groovy/groovyspeed.html

That's interesting, although I think you didn't choose optimal
implementations:

10:16:21 [source]: ruby /c/temp/ruby/fact-bm.rb
Ruby: 54.1 MicroSeconds per call
Ruby: 14.7 MicroSeconds per call
Ruby: 13.5 MicroSeconds per call

and

10:33:25 [groovy]: groovy fact.gr
Groovy: 67.2 MicroSeconds per call
Groovy: 59.4 MicroSeconds per call (HotSpot)
Groovy: 57.9 MicroSeconds per call
Groovy: 57.8 MicroSeconds per call (HotSpot)
Groovy: 57.8 MicroSeconds per call
Groovy: 57.8 MicroSeconds per call (HotSpot)

Darn, I didn't expect groovy to be *that* slow.

Kind regards

robert
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,159
Messages
2,570,879
Members
47,413
Latest member
ReeceDorri

Latest Threads

Top