Linearly Used Continuations
Continuations are the raw material of control. They can
be used to explain a wide variety of control behaviours,
including calling/returning (procedures), raising/handling
(exceptions), labelled jumping (goto statements), process
switching (coroutines), and backtracking. In the most powerful
form, represented by callcc and its cousins, the programmer
can manipulate continuations as first-class values.
It can be argued, however, that unrestricted use of continuations,
especially when combined with state, can give rise
to intractable higher-order spaghetti code. Hence, few languages
give the user direct, reified, access to continuations;
rather, they are "behind the scenes", implementing other
control behaviours, and their use is highly stylised.
But just what is this stylised usage? Remarkably, as we
will argue, in many forms of control, continuations are used
linearly. This is true for a wide range of effects, including
procedure call and return, exceptions, goto statements, and
coroutines.
I feel this is related to the The pi-Calculus in Direct Style, in the sense that it analyzes cases when you do not want full power of first-class continuations or CPS. This is just a vague feeling and not a scientific remark. Therefore, it's not a story, either :-)
Recent comments
22 weeks 6 days ago
22 weeks 6 days ago
22 weeks 6 days ago
45 weeks 19 hours ago
49 weeks 2 days ago
50 weeks 6 days ago
50 weeks 6 days ago
1 year 1 week ago
1 year 6 weeks ago
1 year 6 weeks ago