[pypy-svn] rev 1483 - pypy/trunk/src/pypy/translator/test
hpk at codespeak.net
hpk at codespeak.net
Tue Sep 30 19:40:14 CEST 2003
Author: hpk
Date: Tue Sep 30 19:40:12 2003
New Revision: 1483
Modified:
pypy/trunk/src/pypy/translator/test/make_dot.py
Log:
added class name to boxes
Modified: pypy/trunk/src/pypy/translator/test/make_dot.py
==============================================================================
--- pypy/trunk/src/pypy/translator/test/make_dot.py (original)
+++ pypy/trunk/src/pypy/translator/test/make_dot.py Tue Sep 30 19:40:12 2003
@@ -34,9 +34,9 @@
def descr_edges(self):
l = []
+ style = self.linestyle()
for node,name in self.edges:
if node in self.allnodes:
- style = node.linestyle()
l.append('edge [style=%s, label="%s"]; %s -> %s;' % (style, name, self, node))
else:
pass
@@ -46,7 +46,9 @@
return "solid"
def get_data(self):
- return "\\n".join(self.data)
+ l = self.data[:]
+ l.insert(0, "%s" % self.obj.__class__.__name__)
+ return "\\n".join(l)
def __str__(self):
return self.name
@@ -83,6 +85,9 @@
data = self.get_data()
return '%(name)s [shape=box, label="%(data)s"];' % locals()
+ def linestyle(self):
+ return 'dashed'
+
class NodeEndBranch(Node):
def descr_node(self):
""" args, target """
More information about the Pypy-commit
mailing list