mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1061853 - Rename a variable from |member| to |propdef| (referring to the items in an object literal during bytecode emission). r=shu
--HG-- extra : rebase_source : aa5351b3ac87b93bfc16d64780635a92805b5c64
This commit is contained in:
parent
0ea900a2c4
commit
12717b8699
@ -6069,14 +6069,14 @@ EmitObject(ExclusiveContext *cx, BytecodeEmitter *bce, ParseNode *pn)
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
for (ParseNode *member = pn->pn_head; member; member = member->pn_next) {
|
for (ParseNode *propdef = pn->pn_head; propdef; propdef = propdef->pn_next) {
|
||||||
if (!UpdateSourceCoordNotes(cx, bce, member->pn_pos.begin))
|
if (!UpdateSourceCoordNotes(cx, bce, propdef->pn_pos.begin))
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
// Handle __proto__: v specially because *only* this form, and no other
|
// Handle __proto__: v specially because *only* this form, and no other
|
||||||
// involving "__proto__", performs [[Prototype]] mutation.
|
// involving "__proto__", performs [[Prototype]] mutation.
|
||||||
if (member->isKind(PNK_MUTATEPROTO)) {
|
if (propdef->isKind(PNK_MUTATEPROTO)) {
|
||||||
if (!EmitTree(cx, bce, member->pn_kid))
|
if (!EmitTree(cx, bce, propdef->pn_kid))
|
||||||
return false;
|
return false;
|
||||||
obj = nullptr;
|
obj = nullptr;
|
||||||
if (!Emit1(cx, bce, JSOP_MUTATEPROTO))
|
if (!Emit1(cx, bce, JSOP_MUTATEPROTO))
|
||||||
@ -6085,7 +6085,7 @@ EmitObject(ExclusiveContext *cx, BytecodeEmitter *bce, ParseNode *pn)
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* Emit an index for t[2] for later consumption by JSOP_INITELEM. */
|
/* Emit an index for t[2] for later consumption by JSOP_INITELEM. */
|
||||||
ParseNode *key = member->pn_left;
|
ParseNode *key = propdef->pn_left;
|
||||||
bool isIndex = false;
|
bool isIndex = false;
|
||||||
if (key->isKind(PNK_NUMBER)) {
|
if (key->isKind(PNK_NUMBER)) {
|
||||||
if (!EmitNumberOp(cx, key->pn_dval, bce))
|
if (!EmitNumberOp(cx, key->pn_dval, bce))
|
||||||
@ -6109,10 +6109,10 @@ EmitObject(ExclusiveContext *cx, BytecodeEmitter *bce, ParseNode *pn)
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* Emit code for the property initializer. */
|
/* Emit code for the property initializer. */
|
||||||
if (!EmitTree(cx, bce, member->pn_right))
|
if (!EmitTree(cx, bce, propdef->pn_right))
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
JSOp op = member->getOp();
|
JSOp op = propdef->getOp();
|
||||||
MOZ_ASSERT(op == JSOP_INITPROP ||
|
MOZ_ASSERT(op == JSOP_INITPROP ||
|
||||||
op == JSOP_INITPROP_GETTER ||
|
op == JSOP_INITPROP_GETTER ||
|
||||||
op == JSOP_INITPROP_SETTER);
|
op == JSOP_INITPROP_SETTER);
|
||||||
|
Loading…
Reference in New Issue
Block a user