Default scope of variables
Steven D'Aprano
steve+comp.lang.python at pearwood.info
Sun Jul 7 22:23:16 EDT 2013
On Mon, 08 Jul 2013 10:48:03 +1000, Chris Angelico wrote:
[...]
> That means that I, as programmer, have to keep track of the nesting
> level of subtransactions. Extremely ugly. A line of code can't be moved
> around without first checking which transaction object to work with.
I feel your pain, but I wonder why we sometimes accept "a line of code
can't be moved around" as an issue to be solved by the language. After
all, in general most lines of code can't be moved around.
--
Steven
More information about the Python-list
mailing list