Re: [Python-Dev] Make "global after use" a SyntaxError

2016-09-07 Thread Rob Cliffe
I don't know if feedback from a single, humble Python programmer is of any value, but: +1 I do sometimes have global statements at the start of the bit of code to which they apply (rather than having all global statements agglomerated at the start of the function they are in). This seems to

Re: [Python-Dev] Make "global after use" a SyntaxError

2016-09-07 Thread Guido van Rossum
+1 On Wed, Sep 7, 2016 at 7:10 AM, Ivan Levkivskyi wrote: > Hi all, > > The documentation at https://docs.python.org/3/reference/simple_stmts.html > says that: > > "Names listed in a global statement must not be used in the same code block > textually preceding that global statement" > > But then

[Python-Dev] Make "global after use" a SyntaxError

2016-09-07 Thread Ivan Levkivskyi
Hi all, The documentation at https://docs.python.org/3/reference/simple_stmts.html says that: "Names listed in a global statement must not be used in the same code block textually preceding that global statement" But then later: "CPython implementation detail: The current implementation does no