Minor tweaks

This commit is contained in:
rocky
2016-05-05 22:09:22 -04:00
parent 408ba8c564
commit 163dfd888d
3 changed files with 17 additions and 10 deletions

View File

@@ -1075,14 +1075,12 @@ class SourceWalker(GenericASTTraversal, object):
else:
buildclass = node[0]
build_list = buildclass[1][0]
subclass = buildclass[-3][0].attr
currentclass = buildclass[0].pattr
if hasattr(buildclass[-3][0], 'pattr'):
if hasattr(buildclass[-3][0], 'attr'):
subclass = buildclass[-3][0].attr
currentclass = buildclass[0].pattr
elif hasattr(node[0][0], 'pattr'):
currentclass = node[0][0].pattr
subclass = buildclass[-3][1].attr
currentclass = node[0][0].pattr
else:
raise 'Internal Error n_classdef: cannot find class name'