cl-uglify-js
cl-uglify-js copied to clipboard
slight usability improvement to build/main.lisp
When parsing fails, the standalone program currently drops into the SBCL debugger, which is fine when running cl-uglify-js from the command line, but not easy to handle when running cl-uglify-js from a script, for example via Python's subprocess.Popen facility.
This change makes the main function catch any parse-js:js-parse-errors that are raised, log the line and column numbers to *error-output*, and return an empty string.