fat / smoosh

something like a himalountain.
342 stars 21 forks source link

Fix missing ending semicolon in UglifyJS output #23

Open thibaudcolas opened 10 years ago

thibaudcolas commented 10 years ago

When files processed with smoosh (UglifyJS) are concatenated to other files, there may be a bug because of a missing semicolon at the end of the compressed output. I encountered this problem when using ded/domready's minified version, which has been created with smoosh.

The fix is directly taken from the UglifyJS source code. It has to be taken care of in smoosh's code too because smoosh directly uses the UglifyJS v1 API. In UglifyJS, the semicolon is also added after the gen_code(ast) call.