mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Merge backout of 7cd22106e8d9
This commit is contained in:
commit
1126a8783f
@ -1843,17 +1843,34 @@ EmitEnterBlock(JSContext *cx, JSParseNode *pn, JSCodeGenerator *cg)
|
||||
static bool
|
||||
MakeUpvarForEval(JSParseNode *pn, JSCodeGenerator *cg)
|
||||
{
|
||||
JSContext *cx = cg->compiler->context;
|
||||
JSFunction *fun = cg->compiler->callerFrame->fun;
|
||||
uintN upvarLevel = fun->u.i.script->staticLevel;
|
||||
|
||||
JSFunctionBox *funbox = cg->funbox;
|
||||
while (funbox && funbox->level >= upvarLevel) {
|
||||
if (funbox->node->pn_dflags & PND_FUNARG)
|
||||
if (funbox) {
|
||||
/*
|
||||
* Treat top-level function definitions as escaping (i.e., as funargs),
|
||||
* required since we compile each such top level function or statement
|
||||
* and throw away the AST, so we can't yet see all funarg uses of this
|
||||
* function being compiled (cg->funbox->object). See bug 493177.
|
||||
*/
|
||||
if (funbox->level == fun->u.i.script->staticLevel + 1U &&
|
||||
!(((JSFunction *) funbox->object)->flags & JSFUN_LAMBDA)) {
|
||||
JS_ASSERT_IF(cx->options & JSOPTION_ANONFUNFIX,
|
||||
((JSFunction *) funbox->object)->atom);
|
||||
return true;
|
||||
funbox = funbox->parent;
|
||||
}
|
||||
|
||||
while (funbox->level >= upvarLevel) {
|
||||
if (funbox->node->pn_dflags & PND_FUNARG)
|
||||
return true;
|
||||
funbox = funbox->parent;
|
||||
if (!funbox)
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
JSContext *cx = cg->compiler->context;
|
||||
JSAtom *atom = pn->pn_atom;
|
||||
|
||||
uintN index;
|
||||
|
@ -256,7 +256,7 @@ struct VMSideExit : public nanojit::SideExit
|
||||
* Ordinarily 0. If a slow native function is atop the stack, the 1 bit is
|
||||
* set if constructing and the other bits are a pointer to the funobj.
|
||||
*/
|
||||
uintN nativeCalleeWord;
|
||||
uintptr_t nativeCalleeWord;
|
||||
|
||||
JSObject * nativeCallee() {
|
||||
return (JSObject *) (nativeCalleeWord & ~1);
|
||||
@ -267,7 +267,7 @@ struct VMSideExit : public nanojit::SideExit
|
||||
}
|
||||
|
||||
void setNativeCallee(JSObject *callee, bool constructing) {
|
||||
nativeCalleeWord = uintN(callee) | constructing;
|
||||
nativeCalleeWord = uintptr_t(callee) | (constructing ? 1 : 0);
|
||||
}
|
||||
};
|
||||
|
||||
|
@ -95,7 +95,7 @@ nsBulletFrame::Destroy()
|
||||
{
|
||||
// Stop image loading first
|
||||
if (mImageRequest) {
|
||||
mImageRequest->Cancel(NS_ERROR_FAILURE);
|
||||
mImageRequest->CancelAndForgetObserver(NS_ERROR_FAILURE);
|
||||
mImageRequest = nsnull;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user