Mercurial > pysmcl
changeset 331:78c40a179bab
flow: Made the dot-graph generation deterministic
By sorting the child-lists before processing them
author | Sigurd Meldgaard <stm@daimi.au.dk> |
---|---|
date | Tue, 06 Jul 2010 16:13:07 +0200 |
parents | 8379a9bac9c0 |
children | 06abdeadde6e |
files | pysmcl/flow.py |
diffstat | 1 files changed, 1 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/pysmcl/flow.py Mon Jul 05 15:12:42 2010 +0200 +++ b/pysmcl/flow.py Tue Jul 06 16:13:07 2010 +0200 @@ -149,7 +149,7 @@ def depth_first(entry): node = graph.add_node([], pretty(entry)) processed[entry] = node - for child in entry.children: + for child in sorted(entry.children, key=lambda x: pretty(x)): if not child in processed: depth_first(child) node.out.append(processed[child])