Skip to content

Fix missing TS1110 on function signatures with one parameter #823

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Sep 10, 2019

Conversation

dcodeIO
Copy link
Member

@dcodeIO dcodeIO commented Sep 6, 2019

potentially fixes #822

As mentioned in #822 (comment) we were missing a diagnostic here in the (identifier) case, which is ambiguous in that it can be either a parenthesized or a function type without parsing further. The fix is a bit awkward because the parser cannot look ahead more than one token, so it remembers the potentially erroneous parameter and issues the diagnostic once it is sure that it is dealing with a function type. Also adds parameters with an omitted type to the AST fwiw (serialization purposes maybe).

@dcodeIO dcodeIO merged commit 09f0f17 into master Sep 10, 2019
@dcodeIO dcodeIO deleted the issue-822 branch November 8, 2019 02:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Callback function needs name gotcha
1 participant