July 9th Thursday (七月 九日 木曜日)

来源:互联网 发布:手机常用月历软件 编辑:程序博客网 时间:2024/04/28 14:33

Continuation Frames and Marks

  Every continuation C can be partitioned into continuation frames C1, C2, ..., Cn such that C = C1[C2[...[Cn]]], and no frame Ci can be itself partitioned into smaller continuations. Evaluation steps add and remove frames to the current continuation, typically one at a time.

  Each frame is conceptually annotated with a set of continuation marks. A mark consists of a key and its value; the key is an arbitrary value, and each frame includes at most one mark for any key. Various operations set and extract marks from continuations, so that marks can be used to attach information to a dynamic extent. For example, marks can be used to record information for a “stack trace” to be used when an exception
is raised, or to implement dynamic scope.