Skip to content

Commit

Permalink
Merge branch 'horizontal-call-graph' of github.com:DanielVF/slither i…
Browse files Browse the repository at this point in the history
…nto DanielVF-horizontal-call-graph
  • Loading branch information
montyly committed Dec 6, 2024
2 parents bcd0f83 + 730d035 commit 10774d1
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion slither/printers/call/call_graph.py
Original file line number Diff line number Diff line change
Expand Up @@ -257,6 +257,8 @@ def output(self, filename: str) -> Output:
}
content = "\n".join(
["strict digraph {"]
+ ["rankdir=\"LR\""]
+ ["node [shape=box]"]
+ [_process_functions(list(all_functions_as_dict.values()))]
+ ["}"]
)
Expand All @@ -268,7 +270,11 @@ def output(self, filename: str) -> Output:
with open(derived_output_filename, "w", encoding="utf8") as f:
info += f"Call Graph: {derived_output_filename}\n"
content = "\n".join(
["strict digraph {"] + [_process_functions(derived_contract.functions)] + ["}"]
["strict digraph {"]
+ ["rankdir=\"LR\""]
+ ["node [shape=box]"]
+ [_process_functions(derived_contract.functions)]
+ ["}"]
)
f.write(content)
results.append((derived_output_filename, content))
Expand Down

0 comments on commit 10774d1

Please sign in to comment.