Bug #807380: Report to the compiler the function is constructing when entering at a branch, r=dvander

This commit is contained in:
Hannes Verschore 2012-11-02 11:45:25 +01:00
parent d5189b4ea2
commit a7b9fd1684

View File

@ -1270,7 +1270,7 @@ ion::CanEnterAtBranch(JSContext *cx, HandleScript script, StackFrame *fp, jsbyte
// Attempt compilation. Returns Method_Compiled if already compiled.
JSFunction *fun = fp->isFunctionFrame() ? fp->fun() : NULL;
MethodStatus status = Compile(cx, script, fun, pc, false);
MethodStatus status = Compile(cx, script, fun, pc, fp->isConstructing());
if (status != Method_Compiled) {
if (status == Method_CantCompile)
ForbidCompilation(cx, script);