Hacker News new | past | comments | ask | show | jobs | submit login

MacRuby is extremely impressive, even if you aren't much of a Ruby guy (like me.) It lets me do nearly everything I'd want to do in a Cocoa application, but much more easily than with C/Objective-C. It really is fantastic, and a lot of work has been put in to make it easy to integrate with other software (both as a host and a guest – there's a direct object mapping, no bridges or anything.)

I'm sure a lot of people think "yeah but what about performance?" and from what I've seen, direct calls/messages on objects are faster in MacRuby than Objective-C. Writing with just C (and no Obj-C messaging) is still going to be a lot faster, though.

But you rarely hear people complaining about messaging not being fast enough in Objective-C. You probably wouldn't be using messaging in those situations anyway.

Edit addendum: Since I know there are a lot of fellow functional programmers here on HN, I'd like to add that MacRuby has added real tail-call optimization, and (I was surprised to find this out recently) that Ruby has continuations with callcc. It's very, very nice. It's not exactly Lisp, but it's damn good and the platform integration blows anything existing away.




you rarely hear people complaining about messaging not being fast enough in Objective-C

There was a big spate of it ~4 years ago -- people had been using method dispatch in tight loops, and boggled a bit at the numbers when they started using Apple's fantastic Shark profiler. objc_msgsend is as cheap as dispatch can be without static linking (way faster than Python or Ruby), but it's still much more expensive than a C function call, and there's nothing keeping you from trading your square brackets and colons for parens and commas.




Consider applying for YC's Spring batch! Applications are open till Feb 11.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: