From b8ae3d01389f1b079303516aca24f61005c89ee1 Mon Sep 17 00:00:00 2001 From: Georg Brandl Date: Wed, 2 May 2007 20:02:29 +0000 Subject: Actually raise an exception before calling ast_error_finish. Triggers an assertion otherwise. --- Python/ast.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Python/ast.c b/Python/ast.c index eb4c68b..be58f53 100644 --- a/Python/ast.c +++ b/Python/ast.c @@ -274,6 +274,8 @@ PyAST_FromNode(const node *n, PyCompilerFlags *flags, const char *filename, return Interactive(stmts, arena); } default: + PyErr_Format(PyExc_SystemError, + "invalid node %d for PyAST_FromNode", TYPE(n)); goto error; } error: -- cgit v0.12