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

Node.js SyntaxError: Unexpected identifier 'boolean' in ANTLR4 JavaScript Lexer #1166

Closed
jj5 opened this issue Apr 10, 2016 · 3 comments
Closed

Comments

@jj5
Copy link

jj5 commented Apr 10, 2016

An issue loading the JavaScript lexer as shown on StackOverflow.

@ericvergnaud
Copy link
Contributor

The ECMAScript.g4 grammar is designed for Java only.
To use it with JavaScript, you need to translate the Java fragments in the grammar to Javascript.

@jj5
Copy link
Author

jj5 commented Apr 10, 2016

Thanks Eric! I've had a go at translating the Java fragments into JavaScript. Seems to work. You can get a copy of the grammar here: ECMAScript.JavaScriptTarget.g4.

@ericvergnaud
Copy link
Contributor

Hi,
please feel free to submit a pull request to add this grammar to the directory.
Eric

@parrt parrt closed this as completed Dec 10, 2016
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

3 participants