Lichen

tests/nested.py

295:cb64d3e04c11
2016-12-01 Paul Boddie Supported Sliceobj usage, introduced slice step information to __getslice__. Added tests involving slices.
     1 a = 4     2      3 def f(x):     4     def g(y, x=x):     5         def h(z, x=x, y=y):     6             return x, y, z, a     7         return h     8     return g     9     10 fn = f(1)    11 print fn                        # __main__.f.$l0    12 print fn(2)                     # __main__.f.$l0.$l0    13 print fn(2)(3)                  # (1, 2, 3, 4)    14 print fn(2)(3, 5)               # (5, 2, 3, 4)    15 print fn(2)(3, 5, 6)            # (5, 6, 3, 4)