Mercurial > cpython-lru_cache-weakref
diff Python/compile.c @ 3963:00722990b80c legacy-trunk
Removed unused var; added error check for ``lambda: x=1''.
| author | Guido van Rossum <guido@python.org> |
|---|---|
| date | Thu, 08 Aug 1996 18:51:04 +0000 |
| parents | 22e29b1747e1 |
| children | 138fa15a1032 |
line wrap: on
line diff
--- a/Python/compile.c Thu Aug 08 18:49:41 1996 +0000 +++ b/Python/compile.c Thu Aug 08 18:51:04 1996 +0000 @@ -1050,7 +1050,6 @@ struct compiling *c; node *n; { - int i; REQ(n, factor); if (TYPE(CHILD(n, 0)) == PLUS) { com_factor(c, CHILD(n, 1)); @@ -1605,6 +1604,11 @@ return; } break; + + case lambdef: + err_setstr(SyntaxError, "can't assign to lambda"); + c->c_errors++; + return; default: fprintf(stderr, "node type %d\n", TYPE(n));
