Fix duplicate label in es2017 async function

This commit is contained in:
Ron Buckton
2018-02-12 12:30:29 -08:00
parent fca3db440c
commit 6736ced51d
13 changed files with 150 additions and 9 deletions
+1 -1
View File
@@ -153,7 +153,7 @@ namespace ts {
if (statement.kind === SyntaxKind.ForOfStatement && (<ForOfStatement>statement).awaitModifier) {
return visitForOfStatement(<ForOfStatement>statement, node);
}
return restoreEnclosingLabel(visitEachChild(node, visitor, context), node);
return restoreEnclosingLabel(visitEachChild(statement, visitor, context), node);
}
return visitEachChild(node, visitor, context);
}