Refactor execute_operation a bit

This commit is contained in:
Dave Halter
2020-01-12 13:01:08 +01:00
parent bd2ed8dbbd
commit 11a12d6ca8
7 changed files with 36 additions and 17 deletions

View File

@@ -300,6 +300,17 @@ some_dct['b']
#? int() float() str()
some_dct['c']
class Foo:
pass
objects = {object(): 1, Foo: '', Foo(): 3.0}
#? int() float() str()
objects[Foo]
#? int() float() str()
objects[Foo()]
#? int() float() str()
objects['']
# -----------------
# with variable as index
# -----------------