So although I love SML with all my heart, I'd kind of like to find a "cool" language that I can actually write a GUI program with. And these days, GUI means Object Oriented Programming.
So I went over to check on my first and favoritest OOPL, Smalltalk.
The premier "experimenter's" version of Smalltalk these days is Squeak. Squeak is an extremely portable and complete implementation of Smalltalk 80 (the closest thing to an "ANSI Smalltalk" there is, really) combined with some extremely odd ideas about UI design. Squeak is a whole computer environment, and is really meant to be like the old Smalltalk machines of the 80's, where Squeak is your OS, Application, Devsystem, etc. As such, it's very cool and has web browsers and email systems built into the IDE. If you run it full screen, you can even imagine you're using a magical, alternative computer system, seeing things they way they could have been had Microsoft and Apple not taken over "the dream".
And who wouldn't love Smalltalk? A language in which even the most fundamental things are object oriented, like "if statements". In Smalltalk, you write:
(x < 10) ifTrue: [ "less" ] ifFalse: [ "more" ].
instead of
if (x < 10) "less" else "more";
The result of "(x < 10)" is an object that is either of class True of False. True implements ifTrue:ifFalse: by invoking the first block, False by invoking the second one.
There is no "for" statement, you just send the do: message to an interval of numbers like this:
1 to: 10 do: [ :i | Transcript show: i ].
(That's right: the number 1 is an object that responds to the message to: do: by calling the block of code 10 times with i set to each successive number. Crazy, huh?)
Unfortunately, the current Squeak release seems a little unstable on my PC, and the GUI apps you write are "Squeak" GUI apps that must run in the Squeak environment. Add to that the fact that Squeak has discarded the venerable MVC model that Smalltalk invented in favor of some new VB-like strangeness called "Morphic", and let's just say that it's not the same Smalltalk I used back in the 80's. So hats off to the utopian dream, but I don't think it's going to quite work for me.
This brings us to Ruby. Ruby isn't quite as slick as Smalltalk, and doesn't perform quite as well since it's not (yet) a compiled language, but it sure integrates with modern operating systems better. And it's also a pure OOL, which means it gets a lot of Smalltalk's coolness. I'm still in the early stages of learing Ruby, but so far I like what I see. It just might turn into my OO equivalent of SML - a simple and fun language I can pull out when I need to test out some ideas.
ruby