mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 933798 - Don't unnecessarily deoptimize name accesses in try blocks in lazily parsed functions. r=bhackett
This commit is contained in:
parent
31b7d51b9f
commit
585f6f8712
@ -1140,17 +1140,6 @@ TryConvertFreeName(BytecodeEmitter *bce, ParseNode *pn)
|
||||
* resolving upvar accesses within the inner function.
|
||||
*/
|
||||
if (bce->emitterMode == BytecodeEmitter::LazyFunction) {
|
||||
// The only statements within a lazy function which can push lexical
|
||||
// scopes are try/catch blocks. Use generic ops in this case.
|
||||
for (StmtInfoBCE *stmt = bce->topStmt; stmt; stmt = stmt->down) {
|
||||
switch (stmt->type) {
|
||||
case STMT_TRY:
|
||||
case STMT_FINALLY:
|
||||
return true;
|
||||
default:;
|
||||
}
|
||||
}
|
||||
|
||||
size_t hops = 0;
|
||||
FunctionBox *funbox = bce->sc->asFunctionBox();
|
||||
if (funbox->hasExtensibleScope())
|
||||
|
Loading…
Reference in New Issue
Block a user