Skip to content

Commit 69d9d2c

Browse files
committed
Add a comment for flattenSCC
1 parent befee6b commit 69d9d2c

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

containers/src/Data/Graph.hs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -266,7 +266,8 @@ flattenSCCs = concatMap flattenSCC
266266
-- 'flattenSCC1' has the more precise type.
267267
flattenSCC :: SCC vertex -> [vertex]
268268
flattenSCC (AcyclicSCC v) = [v]
269-
flattenSCC (NECyclicSCC vs) = NE.toList vs
269+
flattenSCC (NECyclicSCC (v :| vs)) = v : vs
270+
-- Note: Best to avoid NE.toList, it is too lazy.
270271

271272
-- | The vertices of a strongly connected component.
272273
--

0 commit comments

Comments
 (0)