This commit is contained in:
Danny Yoo 2013-04-17 17:58:41 -06:00
parent ffc469de40
commit c6b89c6a2e

View File

@ -3145,7 +3145,9 @@
});
// The default prompt handler for a given prompt tag will assume
// it's consuming a zero-argument thunk, and will call it in a
// context where that prompt has been reestablished.
var makeDefaultPromptHandler = function(promptTag) {
return makeClosure(
"default-prompt-handler",
@ -3161,6 +3163,7 @@
[]);
};
// The default abort prompt handler consumes a thunk and applies
// it, in a context where a new prompt has been initialized.
var defaultPromptHandler =
@ -3220,9 +3223,13 @@
} else {
handler = checkProcedure(M, 'call-with-continuation-prompt', 2);
}
} else {
if (promptTag === DEFAULT_CONTINUATION_PROMPT_TAG) {
handler = defaultPromptHandler;
} else {
handler = makeDefaultPromptHandler(promptTag);
}
}
M.p = proc;
if (M.a >= 1) { M.e.pop(); } // the test is redundant, but I want the parallelism.