1
1
mirror of https://github.com/github/semantic.git synced 2024-12-21 22:01:46 +03:00

JavaScript returns can have comments even with no return expression

This commit is contained in:
Timothy Clem 2018-04-13 10:49:48 -07:00
parent a9e5ff6a11
commit 50f3dbae48

View File

@ -622,7 +622,7 @@ withStatement :: Assignment
withStatement = makeTerm <$> symbol WithStatement <*> children (TypeScript.Syntax.With <$> term parenthesizedExpression <*> term statement)
returnStatement :: Assignment
returnStatement = makeTerm <$> symbol ReturnStatement <*> children (Statement.Return <$> (term expressions <|> emptyTerm))
returnStatement = makeTerm <$> symbol ReturnStatement <*> children (Statement.Return <$> (term expressions <|> term emptyTerm))
throwStatement :: Assignment
throwStatement = makeTerm <$> symbol Grammar.ThrowStatement <*> children (Statement.Throw <$> term expressions)