adjusting the stack limit code to be nicer to firefox 3. Also added missing trampoline check in current-print.
This commit is contained in:
parent
f095311284
commit
7ddbd48ba4
|
@ -1,5 +1,7 @@
|
||||||
if(this['plt'] === undefined) { this['plt'] = {}; }
|
if(this['plt'] === undefined) { this['plt'] = {}; }
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// All of the values here are namespaced under "plt.runtime".
|
// All of the values here are namespaced under "plt.runtime".
|
||||||
|
|
||||||
(function(scope) {
|
(function(scope) {
|
||||||
|
@ -92,6 +94,8 @@ if(this['plt'] === undefined) { this['plt'] = {}; }
|
||||||
|
|
||||||
'current-print': new Closure(
|
'current-print': new Closure(
|
||||||
function(MACHINE) {
|
function(MACHINE) {
|
||||||
|
if(--MACHINE.callsBeforeTrampoline<0) { throw arguments.callee; }
|
||||||
|
|
||||||
var elt = MACHINE.env.pop();
|
var elt = MACHINE.env.pop();
|
||||||
var outputPort =
|
var outputPort =
|
||||||
MACHINE.params.currentOutputPort;
|
MACHINE.params.currentOutputPort;
|
||||||
|
@ -1304,7 +1308,7 @@ if(this['plt'] === undefined) { this['plt'] = {}; }
|
||||||
setTimeout(function() {
|
setTimeout(function() {
|
||||||
findStackLimit(function(v) {
|
findStackLimit(function(v) {
|
||||||
// Trying to be a little conservative.
|
// Trying to be a little conservative.
|
||||||
STACK_LIMIT_ESTIMATE = Math.floor(v / 2);
|
STACK_LIMIT_ESTIMATE = Math.floor(v / 10);
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
0);
|
0);
|
||||||
|
|
Loading…
Reference in New Issue
Block a user