From: Simon Strandgaard Date: 2004-01-30T21:04:53+09:00 Subject: Re: fallbacks using contiuations On Fri, 30 Jan 2004 15:04:17 +0900, Jim Weirich wrote: > > Joel VanderWerf said: >> >> Here is an amusing little control structure that shows off ruby's >> continuations and is actually useful (of course, you might want to use >> something other than a global variable--that's just for simplicity): > > Stuff like this is so cool ... [snip] > I suppose I should post the code for Amb. Here it is ... [snip] Nice nicE! I am working on a regexp engine which uses same kind of logic, but without using continuations. Instead I use a stack for backtracking. Amb is a nice implementation/inspiration for improvement. -- Simon Strandgaard