fixes #438 :: scope attribute broke with dmdfe 1.062 upgrade; thanks to SiegeLord

This commit is contained in:
Moritz Warning
2010-10-30 18:54:59 +02:00
parent 90d9d11def
commit ff5a0f3bd7

View File

@@ -4155,7 +4155,12 @@ Statement *TryFinallyStatement::syntaxCopy()
Statement *TryFinallyStatement::semantic(Scope *sc)
{
//printf("TryFinallyStatement::semantic()\n");
// This code is different in LDC because LDC needs to know the
// enclosingScopeExit for its labels
Statement* oldScopeExit = sc->enclosingScopeExit;
sc->enclosingScopeExit = this;
body = body->semantic(sc);
sc->enclosingScopeExit = oldScopeExit;
sc = sc->push();
sc->enclosingFinally = this;
sc->sbreak = NULL;