zaach / jison

Bison in JavaScript.
http://jison.org
4.36k stars 450 forks source link

Add parameter in the command-line tools to support specifying moduleName #282

Open sammyhk opened 9 years ago

sammyhk commented 9 years ago

As titled, seems the moduleName is computed by the input/ output file name now, but it is not passed to the code generation function. Requested to enhance this by adding another parameter in the CLI to support specifying the moduleName (and do no keep computing the module name, this is not working now, so it is safe to remove this for backward compatibility).

Proposed CLI parameter: -n NAME, --module-name NAME The name of the generated parser object, namespace supported