Back out the patch from bug 354392 to rule it out as a cause of the Mac tinderbox bustage

This commit is contained in:
gavin%gavinsharp.com 2006-10-03 23:59:55 +00:00
parent e39fbcb68e
commit aca136ba3e
3 changed files with 4 additions and 12 deletions

View File

@ -3109,9 +3109,9 @@ js_EmitFunctionBody(JSContext *cx, JSCodeGenerator *cg, JSParseNode *body,
if (!ok)
return JS_FALSE;
if (!js_NewScriptFromCG(cx, cg, fun))
fun->u.i.script = js_NewScriptFromCG(cx, cg, fun);
if (!fun->u.i.script)
return JS_FALSE;
JS_ASSERT(FUN_INTERPRETED(fun));
if (cg->treeContext.flags & TCF_FUN_HEAVYWEIGHT)
fun->flags |= JSFUN_HEAVYWEIGHT;

View File

@ -826,7 +826,8 @@ js_CompileFunctionBody(JSContext *cx, JSTokenStream *ts, JSFunction *fun)
JSMSG_SYNTAX_ERROR);
pn = NULL;
} else {
if (!js_NewScriptFromCG(cx, &funcg, fun)) {
fun->u.i.script = js_NewScriptFromCG(cx, &funcg, fun);
if (!fun->u.i.script) {
pn = NULL;
} else {
if (funcg.treeContext.flags & TCF_FUN_HEAVYWEIGHT)

View File

@ -1329,15 +1329,6 @@ js_NewScriptFromCG(JSContext *cx, JSCodeGenerator *cg, JSFunction *fun)
if (script->trynotes)
js_FinishTakingTryNotes(cx, cg, script->trynotes);
/*
* We initialize fun->u.script to be the script constructed above
* so that the debugger has a valid FUN_SCRIPT(fun).
*/
if (fun) {
JS_ASSERT(FUN_INTERPRETED(fun) && !FUN_SCRIPT(fun));
fun->u.i.script = script;
}
/* Tell the debugger about this compiled script. */
js_CallNewScriptHook(cx, script, fun);
return script;