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

Do not allow arrays without comma between values #138

Merged
merged 1 commit into from
Mar 8, 2025

Conversation

jeremyfa
Copy link
Contributor

@jeremyfa jeremyfa commented Mar 7, 2025

When playing with hscript, I noticed that the parser accepts this array without any comma as value separator:

var list = [ "carrot" 1234 null "potato" ];

I don't know if it is an oversight or if it's on purpose, but in my case I needed to forbid it, so here is a pull request of that change.

After the change, the same array needs to be declared like this:

var list = [ "carrot", 1234, null, "potato" ];

Feel free to merge or close that pull request, depending on whether this is intentional or not!

@ncannasse ncannasse merged commit 99a3509 into HaxeFoundation:master Mar 8, 2025
1 check passed
@ncannasse
Copy link
Member

Thanks!

Idklel01 added a commit to idklool-things/hscript that referenced this pull request Mar 13, 2025
Do not allow arrays without comma between values (HaxeFoundation#138)
@skial skial mentioned this pull request Mar 17, 2025
1 task
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.

2 participants