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

Tolerant parsing mode #93

Open
gorkem opened this Issue Nov 16, 2015 · 1 comment

Comments

Projects
None yet
2 participants
@gorkem

gorkem commented Nov 16, 2015

Provide a new mode of parsing that Instead of throwing an exception and aborting parsing on the first JS error encoutered, parser attempts to continue parsing and provides collections of all the syntax errors.

@angelozerr

This comment has been minimized.

Show comment
Hide comment
@angelozerr

angelozerr Nov 25, 2015

This issue is required to integrate shift inside any editor, because editor needs to maintain a valid AST even if editor content doesn't contain valid content (when editor user is typing some content and open completion for instance)

acorn/esprima provides this feature (loose parser), and can be used in any editor. tern which uses acorn is a sample http://ternjs.net/doc/demo/

IMHO, If you can provide loose parser, a lot of IDE could use shift.

This issue is required to integrate shift inside any editor, because editor needs to maintain a valid AST even if editor content doesn't contain valid content (when editor user is typing some content and open completion for instance)

acorn/esprima provides this feature (loose parser), and can be used in any editor. tern which uses acorn is a sample http://ternjs.net/doc/demo/

IMHO, If you can provide loose parser, a lot of IDE could use shift.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment