commit | 7f751bec39459c9799f0d0553589e6193c1c00a4 | [log] [tgz] |
---|---|---|
author | Aaron Meurer <asmeurer@gmail.com> | Fri Nov 13 12:31:40 2015 |
committer | Phil Frost <indigo@bitglue.com> | Fri Nov 13 12:33:34 2015 |
tree | be4a5e60496cf2699275d44e7db580d115ca51c8 | |
parent | 93aa3c435505b8541b151c3e4b24c0ec4333f0bb [diff] |
Check for non-ast SyntaxErrors This includes return and yield outside of a function and break and continue outside of a loop. Fixes lp 1293654. The problem is that these SyntaxErrors are not encoded in the ast grammar, so they are not detected when just compiling to ast. You must compile down to bytecode to catch them. The advantage here is that we can still check for other kinds of errors in this case, because the ast is still valid.