Guard identifier on compiled JS #9
Labels
good first issue
Good for newcomers
scope: compiler-js
Affecting JS compiler
type: bug
Something isn't working
Currently we can use any reserved word/token (such as
var
,if
, etc) as identifier in naskah which won't be valid JS. The simplest thing we can do is add underscore before printing the identifier if it's a reserved word in JSSo that:
should be compiled to
The text was updated successfully, but these errors were encountered: