A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2009-November/094269.html below:

[Python-Dev] global statements outside functions/methods should raise SyntaxError

[Python-Dev] global statements outside functions/methods should raise SyntaxError [Python-Dev] global statements outside functions/methods should raise SyntaxErrorMRAB python at mrabarnett.plus.com
Sun Nov 15 21:31:39 CET 2009
Benjamin Peterson wrote:
> 2009/11/15 Michael Foord <fuzzyman at voidspace.org.uk>:
>> Well, personally I think it would be a good thing if this raised an
>> exception during bytecode compilation - but it would fall under the
>> moratorium and have to wait a few years.
> 
> It could probably be considered a bug, though, since the global
> statement in that case silently has absolutely no effect.
> 
It wouldn't be adding a new feature, but it would be changing the
behaviour of programs that currently have 'global' outside a function.

Perhaps, due to the moratorium, there should be a warning before it's
actually corrected.
More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4