From: Henry Maddocks Date: 2006-11-26T07:23:44+09:00 Subject: Re: Ruby vs Java vs c++ On 22/11/2006, at 7:16 AM, David Vallner wrote: > And conversely, what's the problem with using C++ instead of C for > performance-critical Ruby extensions or any "fast code"? Don't know. Just seems that most prefer c when writing extensions etc. I haven't found the need yet so until I give it a go I'm just going by what I see. rubyinline looks pretty interesting. Does that support c++? > It's not THAT > much overhead compared to pure C, and I'd bet money on that it'll be > less than the cost of interpreter callouts (in doing data structure > marshalling or manipulating Ruby objects as opposed to not having > to for > a straight C++ app) is. The heaps and piles (I know, I can get > cream for > that) of inconsistency inside C would make that overhead worth it for > me, as well as the fact that doing robust code is horrible busywork. Don't get what you mean? Are you saying C++ is less complicated then c for writing ruby extensions or just fast code in general? Either way that's quite a statement. > Also, for gaming, .NET seems to be gaining hold recently, if the > (sometimes amusingly tangled) dependencies new stuff has on it are a > reliable hint, although I can't tell which of the C# syntax > flavours it > is that's being used, obviously. That's true but not all games are THAT performance critical. I've written several 3D games in ruby without any performance problems but then you're not going to use ruby to write Doom 3.