[issue28681] About function renaming in the tutorial

2020-07-05 Thread Joannah Nanjekye
Change by Joannah Nanjekye : -- nosy: +nanjekyejoannah nosy_count: 8.0 -> 9.0 pull_requests: +20488 stage: needs patch -> patch review pull_request: https://github.com/python/cpython/pull/21340 ___ Python tracker

[issue28681] About function renaming in the tutorial

2017-04-04 Thread Jim Fasarakis-Hilliard
Changes by Jim Fasarakis-Hilliard : -- nosy: +Jim Fasarakis-Hilliard ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscr

[issue28681] About function renaming in the tutorial

2016-11-18 Thread Vedran Čačić
Vedran Čačić added the comment: Obligatory link: https://www.kalzumeus.com/2010/06/17/falsehoods-programmers-believe-about-names/ :-P Yes, Python objects are simpler than people, but still not completely trivial. The core issue is "who does the calling". Even one's native language might subtl

[issue28681] About function renaming in the tutorial

2016-11-18 Thread Terry J. Reedy
Terry J. Reedy added the comment: It took me a moment to realize that 'value of the function name' meant 'the function object associated with the name'. I think David's rewrite is a substantial improvement. I would just change the end 'can be used as a function' to 'can be used to access the

[issue28681] About function renaming in the tutorial

2016-11-13 Thread R. David Murray
R. David Murray added the comment: I would rewrite that paragraph as follows: A function definition associates the function name with the function object in the current symbol table. The interpreter recognizes the object pointed to by that name as a user-defined function. Other nam

[issue28681] About function renaming in the tutorial

2016-11-13 Thread Steven D'Aprano
Steven D'Aprano added the comment: > And this is aliasing: > g = f Is it only aliasing if you know that f is a function? I don't mean that as a rhetorical question -- I'm asking if we're comfortable with the idea of saying that g is an alias when f is (say) a float. -- _

[issue28681] About function renaming in the tutorial

2016-11-12 Thread Raymond Hettinger
Raymond Hettinger added the comment: To me, this is renaming: def f(x): pass f.__name__ = g And this is aliasing: g = f -- ___ Python tracker ___ __

[issue28681] About function renaming in the tutorial

2016-11-12 Thread Steven D'Aprano
Steven D'Aprano added the comment: I disagree that "aliasing" is more accurate. We have a perfectly good name for symbols in Python: "name". A value (and that includes functions) can have multiple names. It seems to me that if we're to start distinguishing between names and aliases, then alias

[issue28681] About function renaming in the tutorial

2016-11-12 Thread Raymond Hettinger
Raymond Hettinger added the comment: +1 "Aliasing" is more accurate. -- nosy: +rhettinger ___ Python tracker ___ ___ Python-bugs-list

[issue28681] About function renaming in the tutorial

2016-11-12 Thread Xue Fuqiao
New submission from Xue Fuqiao: In https://hg.python.org/cpython/file/6fbb7c9d77c6/Doc/tutorial/controlflow.rst#l295 : A function definition introduces the function name in the current symbol table. The value of the function name has a type that is recognized by the interpreter as a u