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

Operators are allowed in var declaration #107

Open
kLabz opened this issue Jul 7, 2021 · 0 comments · May be fixed by #108
Open

Operators are allowed in var declaration #107

kLabz opened this issue Jul 7, 2021 · 0 comments · May be fixed by #108

Comments

@kLabz
Copy link

kLabz commented Jul 7, 2021

This works, while it shouldn't.

var script = "
	var sum == 1; // Or any other operator? Same with `var sum > 1;`
	sum;
";
var parser = new hscript.Parser();
var program = parser.parseString(script);
var interp = new hscript.Interp();
trace( interp.execute(program) ); // null
@kLabz kLabz linked a pull request Jul 7, 2021 that will close this issue
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 a pull request may close this issue.

1 participant