Skip to content
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

+1 is considered valid syntax #62

Closed
jfmengels opened this issue Jun 16, 2020 · 1 comment
Closed

+1 is considered valid syntax #62

jfmengels opened this issue Jun 16, 2020 · 1 comment

Comments

@jfmengels
Copy link
Collaborator

As shown (roughly) here, +1 is parsed and considered as valid syntax, even though Elm rejects it with a syntax error.

It seems to be parsed as OperationApplication "+" Right (Application []) (Int 1). The Application is obviously invalid, and I am not sure how this will turn out in v8, where it has become a non-empty list. Also, its range is the emptyRange (0,0,0,0).

++1 also seems to compile even though it shouldn't.

@stil4m stil4m closed this as completed in ecffddc Jun 21, 2020
@stil4m
Copy link
Owner

stil4m commented Jun 21, 2020

Fixed this. Both +1 and 1+ (same for other operators) are not accepted as valid syntax anymore and will not be parsed.

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

No branches or pull requests

2 participants