Start handling Pyton 2.4 bytecodes

This commit is contained in:
rocky
2016-07-08 14:56:57 -04:00
parent 7fdb4d3e68
commit 62e60817f6
17 changed files with 125 additions and 21 deletions

View File

@@ -961,8 +961,9 @@ class SourceWalker(GenericASTTraversal, object):
n_import_as_cont = n_import_as
def n_importfrom(self, node):
if node[0].pattr > 0:
node[2].pattr = '.'*node[0].pattr+node[2].pattr
relative_path_index = 0
if self.version >= 2.5 and node[relative_path_index].pattr > 0:
node[2].pattr = '.'*node[relative_path_index].pattr + node[2].pattr
self.default(node)
n_importstar = n_importfrom