micropython

Annotated tests/failure/argument_shortage.py

288:54a2867eb465
2009-11-23 Paul Boddie Added attribute usage registration for branches where more specific attribute usage occurs, but where such usage cannot be merged back into the active usage definition for a given name. This should ensure that attributes are not forgotten because their usage was not merged and carried forward. Added more specific tests.
paul@59 1
#!/usr/bin/env python
paul@59 2
paul@59 3
def f(a, b, c):
paul@59 4
    pass
paul@59 5
paul@59 6
g = f
paul@59 7
g(1, 2) # uncertain target - not detected
paul@59 8
paul@59 9
def g(a, c, b):
paul@59 10
    pass
paul@59 11
paul@59 12
g(1, a=3, b=2)
paul@59 13
paul@59 14
f(1, 2, 3)
paul@59 15
f(1, 2)
paul@59 16
paul@59 17
# vim: tabstop=4 expandtab shiftwidth=4