victordiaz / PHONK

PHONK is a coding playground for new and old Android devices
https://phonk.app
GNU General Public License v3.0
456 stars 27 forks source link

Missing ; after statement #76

Closed EuphoricPenguin closed 3 years ago

EuphoricPenguin commented 3 years ago

let a = 2; results in a ASI error where the code won't run, meaning variables are effectively useless. This happens with var as well, and seems to happen from a numerated "run" of the code. I'm running a Pixel 4 on the latest stable release of Android 10. I installed the latest extended release of PHONK, and ran into this issue.

victordiaz commented 3 years ago

Hi @EuphoricPenguin

let is not supported since the Rhino Javascript interpreter does run modern jacascript (ie ES6). With var should works perfectly. What is the issue that you are facing with var?

EuphoricPenguin commented 3 years ago

Identical issue. Seems to be working now actually. Thank you for informing me of the situation with ES6.

victordiaz commented 3 years ago

There is this issue describing the problem with the current interpreter.

https://github.com/victordiaz/PHONK/issues/4

Feel free to join the discussion there :)

victordiaz commented 3 years ago

Hi @EuphoricPenguin I close the issue since it seems that it is solved. I will try to put some Warnings somewere to indicate that ES6 is not supported :)

Thanks