Cherow ECMAparser 1.0 beta is out

6 points by cherow ↗ HN
Still in beta stage, but with improved performance.

URL: https://github.com/cherow/cherow

5 comments

[ 3.5 ms ] story [ 30.7 ms ] thread
This project looks really great and all, but one thing I’ve come to appreciate is portable language processing tools. Like this is an js parser in typescript so I have to have node installed to use it (I’m assuming). The trend is language y parser in language y. So I have to install language y environment to use it.

I guess I’m saying really portable language parsers would be c libs with wrappers for n languages, or language servers.

Hi. You shouldn't need to have NodeJS installed to use it. Use the distro files and run it in the browser. The TypeScript is not needed for end-users. That something used during the dev process.
what's the usecases for this parser?

I'm mostly interested in writing a docstring document (like jsDoc) generator. So I care if this parser can keep comments. From the readme I saw it does. But from the demo page, I checked "attach comment", but I couldn't see comments in the parsed result.

Hi. Usecases? Same as for Acorn, Esprima and other parsers. But the main goal with this one is to be as fast as possible, and optimized for all platforms including mobile and tablets.

Cherow collect comments. The version before v. 1.0 also kept comment or attached node directly on the AST itself. I removed it due to perf reasons and no one - I thought at least - was using it anymore. If that is something you would need, I can add it back. Shouldn't take long.

Feel free to open an issue ticket on the GH repo so I can track it if you want the comment attachment code added back in.