[issue11418] Method's global scope is module containing function definition, not class.

2012-01-11 Thread Roundup Robot
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset 10a5165103f9 by Terry Jan Reedy in branch '2.7': Minor correction. Closes #11418 http://hg.python.org/cpython/rev/10a5165103f9 New changeset 32ea3675fba2 by Terry Jan Reedy in branch '3.2': Minor correction. #11418

[issue11418] Method's global scope is module containing function definition, not class.

2012-01-09 Thread Terry J. Reedy
Terry J. Reedy tjre...@udel.edu added the comment: This paragraph follows a discussion and example of the fact that methods do *not* have to be defined within a class statement. Any objections to changing The global scope associated with a method is the module containing the class

[issue11418] Method's global scope is module containing function definition, not class.

2012-01-09 Thread INADA Naoki
INADA Naoki songofaca...@gmail.com added the comment: Any objections to changing The global scope associated with a method is the module containing the class definition. (The class itself is never used as a global scope.) to The global scope associated with a method is the module

[issue11418] Method's global scope is module containing function definition, not class.

2011-03-18 Thread Terry J. Reedy
Terry J. Reedy tjre...@udel.edu added the comment: Methods defined within a class may reference... would make the tutorial correct without introducing the complication of methods defined outside a class, let alone in another module. -- nosy: +terry.reedy

[issue11418] Method's global scope is module containing function definition, not class.

2011-03-11 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: I’m afraid I don’t understand “Method's function”. Could you rephrase, or give a commented code example showing the bad behavior? -- nosy: +eric.araujo versions: -Python 2.6 ___ Python tracker

[issue11418] Method's global scope is module containing function definition, not class.

2011-03-11 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: If you do a def foo in module bar.py, and have a class FooFoo in bar.py, and do: FooFoo.myfoo = foo and foo refers to an unbound variable, that variable will be looked up in bar.py's global name space. If instead the 'def foo' is in a

[issue11418] Method's global scope is module containing function definition, not class.

2011-03-06 Thread INADA Naoki
New submission from INADA Naoki songofaca...@gmail.com: http://docs.python.org/py3k/tutorial/classes.html#random-remarks Methods may reference global names in the same way as ordinary functions. The global scope associated with a method is the module containing the class definition. (The

[issue11418] Method's global scope is module containing function definition, not class.

2011-03-06 Thread INADA Naoki
Changes by INADA Naoki songofaca...@gmail.com: -- assignee: - docs@python components: +Documentation nosy: +docs@python versions: +Python 2.6, Python 2.7, Python 3.1, Python 3.2, Python 3.3 ___ Python tracker rep...@bugs.python.org

[issue11418] Method's global scope is module containing function definition, not class.

2011-03-06 Thread Santoso Wijaya
Changes by Santoso Wijaya santoso.wij...@gmail.com: -- nosy: +santa4nt ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11418 ___ ___