# HG changeset patch # User Paul Boddie # Date 1237505563 -3600 # Node ID 59637ebeb668941c21ac1b6cbfe78b63449437b3 # Parent 6f6376544ce5d90feab10f377adac2bb46ffacb8 Fix Attr usage. diff -r 6f6376544ce5 -r 59637ebeb668 micropython/graph.py --- a/micropython/graph.py Thu Mar 19 23:05:55 2009 +0100 +++ b/micropython/graph.py Fri Mar 20 00:32:43 2009 +0100 @@ -82,12 +82,14 @@ for obj in module.all_objects: if isinstance(obj, micropython.inspect.Class): for attr in obj.all_attributes().values(): - if attr.value is not None: - print >>out, ' "%s":%s -> "%s";' % (obj.full_name(), attr.name, get_name(attr.value)) + for value in attr.get_values(): + if value is not None: + print >>out, ' "%s":%s -> "%s";' % (obj.full_name(), attr.name, get_name(value)) elif isinstance(obj, micropython.inspect.Function): for attr in obj.all_locals().values(): - if attr.value is not None: - print >>out, ' "%s":%s -> "%s";' % (obj.full_name(), attr.name, get_name(attr.value)) + for value in attr.get_values(): + if value is not None: + print >>out, ' "%s":%s -> "%s";' % (obj.full_name(), attr.name, get_name(value)) print >>out, ' }' print >>out, "}"