add line numbers to nodes in the except clause (when possible)

This commit is contained in:
Jeremy Hylton 2000-02-15 21:30:48 +00:00
parent ca1ad182f2
commit d603dee4a3
2 changed files with 6 additions and 2 deletions

View File

@ -893,7 +893,9 @@ def com_assign_list(self, node, assigning):
return Node('ass_list', assigns)
def com_assign_name(self, node, assigning):
return Node('ass_name', node[1], assigning)
n = Node('ass_name', node[1], assigning)
n.lineno = node[2]
return n
def com_assign_trailer(self, primary, node, assigning):
t = node[1][0]

View File

@ -893,7 +893,9 @@ def com_assign_list(self, node, assigning):
return Node('ass_list', assigns)
def com_assign_name(self, node, assigning):
return Node('ass_name', node[1], assigning)
n = Node('ass_name', node[1], assigning)
n.lineno = node[2]
return n
def com_assign_trailer(self, primary, node, assigning):
t = node[1][0]