> But what about name mismatches? Global statements allows functions to > create 'new' variables in the module scope and not just 'existing' > ones. What about for in-between scopes? It's probably a misfeature of the global statement that it allows that, but if we're going to re-use it in the form of a "global x in scope" statement, we should keep the behaviour the same for nested scopes in the interests of consistency. Maybe this is an argument for introducing an "outer" statement, which requires an existing binding (determined by existence of an assignment at compile time) even for the module scope, and deprecating "global" altogether. Greg Ewing, Computer Science Dept, +--------------------------------------+ University of Canterbury, | A citizen of NewZealandCorp, a | Christchurch, New Zealand | wholly-owned subsidiary of USA Inc. | greg at cosc.canterbury.ac.nz +--------------------------------------+
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