micropython

tests/op_iadd.py

230:892b13f1cba4
2009-05-30 Paul Boddie Changed instantiator invocation reserving a frame slot regardless of whether the target is known in advance. In the instantiator, the first frame slot is then overwritten with the new instance, and the RecoverFrame instruction is no longer required. Instead, a new JumpInFrame instruction maintains the existing locals, jumping to the initialiser method for the class. Updated various tests, renaming and enhancing the classes test.
     1 #!/usr/bin/env python     2      3 def f(a, b):     4     a += b     5      6 a = 1     7 b = 2     8 a += b     9     10 # vim: tabstop=4 expandtab shiftwidth=4