Difference between revisions of "Continuation"
Karl Jones (Talk | contribs) (Created page with "In computer science and computer programming, a '''continuation''' is an abstract representation of the Control flow|control s...") |
(No difference)
|
Latest revision as of 10:58, 29 November 2016
In computer science and computer programming, a continuation is an abstract representation of the control state of a computer program.
Description
A continuation reifies the program control state, i.e. the continuation is a data structure that represents the computational process at a given point in the process's execution; the created data structure can be accessed by the programming language, instead of being hidden in the runtime environment. Continuations are useful for encoding other control mechanisms in programming languages such as exceptions, generators, coroutines, and so on.
The "current continuation" or "continuation of the computation step" is the continuation that, from the perspective of running code, would be derived from the current point in a program's execution. The term continuations can also be used to refer to first-class continuations, which are constructs that give a programming language the ability to save the execution state at any point and return to that point at a later point in the program, possibly multiple times.
See also
- Call-with-current-continuation
- Closure
- COMEFROM
- Continuation-passing style
- Control flow
- Coroutine
- Delimited continuation
- Denotational semantics
- GOTO
- Spaghetti stack
External links
- Continuation @ Wikipedia