I need to split a JavaScript file into single instructions. For example
a = 2; foo() function bar() { b = 5; print(\"spam\"); }
has to
Forget my parser. https://bitbucket.org/mvantellingen/pyjsparser is great and complete parser. I've fixed a couple of it's bugs here: https://bitbucket.org/nullie/pyjsparser