lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


Someone's just pointed me at this:

http://iolanguage.com/about/

It's a scripting language that seems to be aiming itself directly at Lua; the 
author makes a number of comparisons. Prototype-based OO, syntax reminiscent 
of Smalltalk with a healthy dollop of C and Occam built in. It's very small; 
he claims fewer lines of code than Lua, and a memory footprint ranging from 
64kB to 200kB depending on platform.

There are some very cool features, including intrinsic, stackless, 
coroutine-based threads and built-in future support.

a := someObject
z := a someMethod         # calls synchronously and returns result
z := a @someMethod        # calls asynchronously, z is a future pointing at
                          # the result

z print                   # blocks until z contains a value

This allows you to do things like:

status1 := object1 @init
status2 := object2 @init
status3 := object3 @init
if (status1 | status2 | status3,
	"One of the constructors failed!" print)

Extremely neat.

It definitely has a different philosophy to Lua. Io wants you to do things its 
way (for example, it provides a scheduler and a class hierarchy), where Lua 
provides a framework on which you can hang your own system. But there are 
definitely features worth stealing; I really like its futures, for example. 
I've only ever seen those in functional languages before.

-- 
+- David Given --McQ-+ "For is it not written, wheresoever two or three
|  dg@cowlark.com    | are gathered together, yea they will perform the
| (dg@tao-group.com) | Parrot Sketch?" --- _Not The 9 o'Clock News_
+- www.cowlark.com --+ 

Attachment: pgp4cJ9ECQGyD.pgp
Description: PGP signature