A friend has been playing with the language Io. I spent an hour or so with him on it. Very interesting.
Io is small prototype-based programming language. The ideas in Io are mostly inspired by Smalltalk (all values are objects), Self, NewtonScript and Act1 (prototype-based differential inheritance, actors and futures for concurrency), LISP (code is a runtime inspectable/modifiable tree) and Lua (small, embeddable).The language has an interesting evaluation, reflection, and delegation model. Io has a syntax that does not always require an explicitly denoted receiver for a message. Someone just learning Io can scratch their head once or twice figuring out what's going on.
On the whole though Io is a very simple language with what looks like a simple CPython-like implementation. For programmers looking to understand the "prototypes and delegation" approach to object-oriented programming (as opposed to "classes and inheritance"), then Io seems to be a simple way to dive in deep.
Playing a bit with Io felt a lot like the pre-CLOS days of Lisp in the 1980s when there were a lot of experiments with object systems like ObjVLisp, OakLisp, Loops, etc.
3 comments:
I've never had a chance to really use prototype-based programming, only reading about it from afar. But I'm starting to think my desire for a alternative to the "class" keyword in Python is actually a desire for prototype-based programming.
And then there's JavaScript
http://www.mozilla.org/rhino/scopes.html
hi, if you have used Javascript, then you have used
a prototype based language :-) Look at the .prototype
slot on objects in JS, and you'll find the essence of a
prototype based language.
drudru
Post a Comment