diff options
author | Miss Islington (bot) <31488909+miss-islington@users.noreply.github.com> | 2024-01-18 05:09:26 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-01-18 05:09:26 (GMT) |
commit | e7a5577b53885b9432d201417f0dace22acf6804 (patch) | |
tree | 755364e1fc0c600c20d83810b50c5d32d9ca2368 /Lib/idlelib/stackviewer.py | |
parent | 35e330ba859c915043d2e9808b44120f67328873 (diff) | |
download | cpython-e7a5577b53885b9432d201417f0dace22acf6804.zip cpython-e7a5577b53885b9432d201417f0dace22acf6804.tar.gz cpython-e7a5577b53885b9432d201417f0dace22acf6804.tar.bz2 |
[3.12] gh-96905: In IDLE code, stop redefining built-ins 'dict' and 'object' (GH-114227) (#114228)
Prefix 'dict' with 'o', 'g', or 'l' for 'object', 'global', or 'local'.
Suffix 'object' with '_'.
(cherry picked from commit 6f4b242a03e521a55f0b9e440703b424ed18ce2f)
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
Diffstat (limited to 'Lib/idlelib/stackviewer.py')
-rw-r--r-- | Lib/idlelib/stackviewer.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Lib/idlelib/stackviewer.py b/Lib/idlelib/stackviewer.py index 977c56e..95042d4 100644 --- a/Lib/idlelib/stackviewer.py +++ b/Lib/idlelib/stackviewer.py @@ -106,8 +106,8 @@ class VariablesTreeItem(ObjectTreeItem): value = self.object[key] except KeyError: continue - def setfunction(value, key=key, object=self.object): - object[key] = value + def setfunction(value, key=key, object_=self.object): + object_[key] = value item = make_objecttreeitem(key + " =", value, setfunction) sublist.append(item) return sublist |