ariya/esprima — pull request #37 by joostwim (2012-03-04 13:14:27+00:00)
Title: SyntaxError for 'return' outside function body

Keeps track of function bodies and produces a syntax error when a return statement is encountered outside a function body.

Has been tested in IE6, I did not break compatibility this time :-)

http://code.google.com/p/esprima/issues/detail?id=209