Skip to content

Commit b409dfd

Browse files
committed
for loop fixed
1 parent 7f0aa4d commit b409dfd

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

YantraJS.Core/FastParser/Compiler/FastCompiler.VisitReturnStatement.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ partial class FastCompiler
2020
{
2121
protected override Exp VisitReturnStatement(AstReturnStatement returnStatement) {
2222
return Exp.Return(this.scope.Top.ReturnLabel,
23-
returnStatement.Argument != null
23+
returnStatement.Argument != null && returnStatement.Argument is not AstEmptyExpression
2424
? VisitExpression(returnStatement.Argument)
2525
: JSUndefinedBuilder.Value);
2626
}

0 commit comments

Comments
 (0)