From: Thomas Wouters Date: Mon, 27 Feb 2006 15:43:57 +0000 (+0000) Subject: Fix assertion errors in debug build, brought on by PEP 308 patch. X-Git-Tag: v2.5a0~529 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=fa443cda878b85abb83efb9674df4ff32f6d1b17;p=thirdparty%2FPython%2Fcpython.git Fix assertion errors in debug build, brought on by PEP 308 patch. --- diff --git a/Python/ast.c b/Python/ast.c index 94c877d3cc0f..3f2a9f3e2d4d 100644 --- a/Python/ast.c +++ b/Python/ast.c @@ -537,7 +537,7 @@ seq_for_testlist(struct compiling *c, const node *n) return NULL; for (i = 0; i < NCH(n); i += 2) { - REQ(CHILD(n, i), test); + assert(TYPE(CHILD(n, i)) == test || TYPE(CHILD(n, i)) == old_test); expression = ast_for_expr(c, CHILD(n, i)); if (!expression)