예제 #1
0
 def inner2(x, y):
     filepath, lineno, indent, spans = argspans.argspans(nested=2)
     assert lineno == 49
     assert indent == 4
     assert spans == [((49, 11), (49, 13)), ((49, 15), (49, 20))]
예제 #2
0
 def __eq__(self, rhs):
     filepath, lineno, indent, spans = argspans.argspans()
     assert indent == 4
     assert spans == [((59, 11), (61, 7))]
예제 #3
0
 def foo(x, y):
     filepath, lineno, indent, spans = argspans.argspans()
     assert os.path.basename(filepath) == "test-argspans.py"
     assert lineno == 35
     assert indent == 12
     assert spans == [((35, 16), (35, 17)), ((35, 19), (35, 24))]