On 1 Aug, 2013, at 9:49, Christian Heimes <christ...@python.org> wrote:
> Am 01.08.2013 09:03, schrieb Ronald Oussoren: >> >> On 31 Jul, 2013, at 23:50, christian.heimes <python-check...@python.org> >> wrote: >> >>> http://hg.python.org/cpython/rev/0e09588a3bc2 >>> changeset: 84939:0e09588a3bc2 >>> parent: 84937:809a64ecd5f1 >>> parent: 84938:83a55ca935f0 >>> user: Christian Heimes <christ...@cheimes.de> >>> date: Wed Jul 31 23:48:04 2013 +0200 >>> summary: >>> Silence warning about set but unused variable inside compile_atom() in >>> non-debug builds >>> >>> files: >>> Parser/pgen.c | 1 + >>> 1 files changed, 1 insertions(+), 0 deletions(-) >>> >>> >>> diff --git a/Parser/pgen.c b/Parser/pgen.c >>> --- a/Parser/pgen.c >>> +++ b/Parser/pgen.c >>> @@ -283,6 +283,7 @@ >>> >>> REQ(n, ATOM); >>> i = n->n_nchildren; >>> + (void)i; /* Don't warn about set but unused */ >>> REQN(i, 1); >> >> Why didn't you change this to "REQN(n->nchilderen, 1);" (and then remove >> variable "i")? >> >> Ronald >> >>> n = n->n_child; >>> if (n->n_type == LPAR) { > > It doesn't work because a few lines later the code does: > > n = n->n_child; > if (n->n_type == LPAR) { > REQN(i, 3); > > n is no longer the right n and REQN(i, 3) would fail. I overlooked that one. Thanks for the explanation, Ronald > > Christian > > _______________________________________________ > Python-Dev mailing list > Python-Dev@python.org > http://mail.python.org/mailman/listinfo/python-dev > Unsubscribe: > http://mail.python.org/mailman/options/python-dev/ronaldoussoren%40mac.com _______________________________________________ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com