(via the Icon mailing list)
Our goal is to provide a prototyping tool that facilitates the addition of new language
mechanisms in success/failure based languages. By this, we mean languages that have success and
failure of expressions, generators, and backtracking. We have designed an interpreter, called
FLECS, for a subset of Icon, a language which exhibits the above features. FLECS is written in
Scheme using a technique called continuation-passing-style (CPS).
Success and failure are implemented, as we've seen here before, by having two continuations instead of just one as in Scheme. This is similar to the logic programming implementation in EOPL2.
However, the authors use two more continuations, in order to implement the behaviour of return: an expression can succeed, fail, return a value or return failure (see section 4.5).
Posted to general by Ehud Lamm on 8/11/02; 4:09:02 AM