caught the bug. control after calling the fail continuation wasn't being returned in baselib-functions/internalCallDuringPause. Subtle.
This commit is contained in:
parent
5798e28801
commit
2d7de1f256
|
@ -205,12 +205,12 @@
|
|||
if (! baselib.arity.isArityMatching(proc.racketArity, args.length - 4)) {
|
||||
var msg = baselib.format.format("arity mismatch: ~s expected ~s arguments, but received ~s",
|
||||
[proc.displayName, proc.racketArity, args.length - 4]);
|
||||
fail(baselib.exceptions.makeExnFailContractArity(msg,
|
||||
MACHINE.captureContinuationMarks()));
|
||||
return fail(baselib.exceptions.makeExnFailContractArity(msg,
|
||||
MACHINE.captureContinuationMarks()));
|
||||
}
|
||||
|
||||
if (! isClosure(proc)) {
|
||||
fail(baselib.exceptions.makeExnFail(
|
||||
return fail(baselib.exceptions.makeExnFail(
|
||||
baselib.format.format(
|
||||
"Not a procedure: ~e",
|
||||
[proc]),
|
||||
|
@ -232,7 +232,7 @@
|
|||
MACHINE.v = oldVal;
|
||||
MACHINE.a = oldArgcount;
|
||||
MACHINE.p = oldProc;
|
||||
success(returnValue);
|
||||
return success(returnValue);
|
||||
});
|
||||
};
|
||||
afterGoodInvoke.mvr = function (MACHINE) {
|
||||
|
@ -246,7 +246,7 @@
|
|||
MACHINE.v = oldVal;
|
||||
MACHINE.a = oldArgcount;
|
||||
MACHINE.p = oldProc;
|
||||
success.apply(null, returnValues);
|
||||
return success.apply(null, returnValues);
|
||||
});
|
||||
};
|
||||
|
||||
|
@ -264,7 +264,7 @@
|
|||
MACHINE.p = oldProc;
|
||||
MACHINE.c.length = oldControlLength;
|
||||
MACHINE.e.length = oldEnvLength;
|
||||
fail(e);
|
||||
return fail(e);
|
||||
};
|
||||
MACHINE._trampoline(proc.label,
|
||||
false,
|
||||
|
|
|
@ -1306,15 +1306,15 @@
|
|||
mockView,
|
||||
onGoodWorldUpdate,
|
||||
fail);
|
||||
} else if (isArityMatching(racketWorldCallback.racketArity, 2 + args.length)){
|
||||
} else { //if (isArityMatching(racketWorldCallback.racketArity, 2 + args.length)){
|
||||
console.log("arity match 3");
|
||||
args = ([internalCall, world, mockView]
|
||||
.concat(args)
|
||||
.concat([onGoodWorldUpdate, fail]));
|
||||
racketWorldCallback.apply(null, args);
|
||||
} else {
|
||||
fail(makeArityMismatchError(MACHINE, racketWorldCallback, 2+args.length));
|
||||
}
|
||||
}// else {
|
||||
// fail(makeArityMismatchError(MACHINE, racketWorldCallback, 2+args.length));
|
||||
// }
|
||||
} else {
|
||||
console.log("dispatched all events");
|
||||
dispatchingEvents = false;
|
||||
|
|
Loading…
Reference in New Issue
Block a user