lua-users home
lua-l archive

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


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Roberto Ierusalimschy wrote:
>>      Web sites based on continuations are in use already, but mostly
>> not in Scheme. The Seaside[1] framework is written in Smalltalk and
>> uses them. The Common Lisp frameworks UnCommon Web[2] and Weblocks[3]
>> too.
> 
> But do they benefit from multiple shots?

I know that Seaside does. It uses continuations to 'remember where it was'
when the user backs up through a series of forms. e.g., given code similar to
this:

function doFormSeries()
	drawForm1()
	r1 = getResultFromUser()
	drawForm2()
	r2 = getResultFromUser()
	drawForm3()
	r3 = getResultFromUser()
	performTransaction(r1, r2, r3)
end

(which is all quite doable with Lua coroutines), it allows the user to proceed
up to form 3, then press back to go to form 2, fill in different data, and
continue from there --- and the programmer doesn't have to write any extra
code to make this happen. It's amazingly neat, but does require non-standard
Smalltalk features.

- --
┌── dg@cowlark.com ─── http://www.cowlark.com ───────────────────
│
│ "There does not now, nor will there ever, exist a programming language in
│ which it is the least bit hard to write bad programs." --- Flon's Axiom
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFGzFQJf9E0noFvlzgRAgYhAJ9RHU+kdbY73bnymyRy8AoesF/X0wCeI/D4
bC2pUvYFaZr0Q+9ZzVJEtFM=
=wZMr
-----END PGP SIGNATURE-----