aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--include/llvm/Support/GraphWriter.h8
1 files changed, 2 insertions, 6 deletions
diff --git a/include/llvm/Support/GraphWriter.h b/include/llvm/Support/GraphWriter.h
index 6d1b18e..c89eb55 100644
--- a/include/llvm/Support/GraphWriter.h
+++ b/include/llvm/Support/GraphWriter.h
@@ -247,12 +247,8 @@ public:
if (SrcNodePort >= 0)
O << ":s" << SrcNodePort;
O << " -> Node" << DestNodeID;
- if (DestNodePort >= 0) {
- if (DOTTraits::hasEdgeDestLabels())
- O << ":d" << DestNodePort;
- else
- O << ":s" << DestNodePort;
- }
+ if (DestNodePort >= 0 && DOTTraits::hasEdgeDestLabels())
+ O << ":d" << DestNodePort;
if (!Attrs.empty())
O << "[" << Attrs << "]";