packages feed

Cabal-2.0.1.1: doc/API/Cabal/Distribution-Compat-Graph.html

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Distribution.Compat.Graph</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.0/MathJax.js?config=TeX-AMS-MML_HTMLorMML" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">Cabal-2.0.1.1: A framework for packaging Haskell software</p></div><div id="content"><div id="module-header"><table class="info"><tr><th valign="top">Copyright</th><td>(c) Edward Z. Yang 2016</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>cabal-dev@haskell.org</td></tr><tr><th>Stability</th><td>experimental</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell2010</td></tr></table><p class="caption">Distribution.Compat.Graph</p></div><div id="table-of-contents"><p class="caption">Contents</p><ul><li><a href="#g:1">Graph type</a></li><li><a href="#g:2">Query</a></li><li><a href="#g:3">Construction</a></li><li><a href="#g:4">Combine</a></li><li><a href="#g:5">Graph algorithms</a></li><li><a href="#g:6">Conversions</a><ul><li><a href="#g:7">Maps</a></li><li><a href="#g:8">Lists</a></li><li><a href="#g:9">Sets</a></li><li><a href="#g:10">Graphs</a></li></ul></li><li><a href="#g:11">Node type</a></li></ul></div><div id="description"><p class="caption">Description</p><div class="doc"><p>A data type representing directed graphs, backed by <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/containers-0.5.10.2/Data-Graph.html">Data.Graph</a>.
 It is strict in the node type.</p><p>This is an alternative interface to <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/containers-0.5.10.2/Data-Graph.html">Data.Graph</a>.  In this interface,
 nodes (identified by the <code><a href="Distribution-Compat-Graph.html#t:IsNode">IsNode</a></code> type class) are associated with a
 key and record the keys of their neighbors.  This interface is more
 convenient than <code><a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/containers-0.5.10.2/Data-Graph.html#v:Graph">Graph</a></code>, which requires vertices to be
 explicitly handled by integer indexes.</p><p>The current implementation has somewhat peculiar performance
 characteristics.  The asymptotics of all map-like operations mirror
 their counterparts in <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/containers-0.5.10.2/Data-Map.html">Data.Map</a>.  However, to perform a graph
 operation, we first must build the <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/containers-0.5.10.2/Data-Graph.html">Data.Graph</a> representation, an
 operation that takes <em>O(V + E log V)</em>.  However, this operation can
 be amortized across all queries on that particular graph.</p><p>Some nodes may be broken, i.e., refer to neighbors which are not
 stored in the graph.  In our graph algorithms, we transparently
 ignore such edges; however, you can easily query for the broken
 vertices of a graph using <code><a href="Distribution-Compat-Graph.html#v:broken">broken</a></code> (and should, e.g., to ensure that
 a closure of a graph is well-formed.)  It's possible to take a closed
 subset of a broken graph and get a well-formed graph.</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><span class="keyword">data</span> <a href="#t:Graph">Graph</a> a</li><li class="src short"><span class="keyword">class</span> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Ord.html#t:Ord">Ord</a> (<a href="Distribution-Compat-Graph.html#t:Key">Key</a> a) =&gt; <a href="#t:IsNode">IsNode</a> a <span class="keyword">where</span><ul class="subs"><li><span class="keyword">type</span> <a href="#t:Key">Key</a> a :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a></li></ul></li><li class="src short"><a href="#v:null">null</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Bool.html#t:Bool">Bool</a></li><li class="src short"><a href="#v:size">size</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Int.html#t:Int">Int</a></li><li class="src short"><a href="#v:member">member</a> :: <a href="Distribution-Compat-Graph.html#t:IsNode">IsNode</a> a =&gt; <a href="Distribution-Compat-Graph.html#t:Key">Key</a> a -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Bool.html#t:Bool">Bool</a></li><li class="src short"><a href="#v:lookup">lookup</a> :: <a href="Distribution-Compat-Graph.html#t:IsNode">IsNode</a> a =&gt; <a href="Distribution-Compat-Graph.html#t:Key">Key</a> a -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Maybe.html#t:Maybe">Maybe</a> a</li><li class="src short"><a href="#v:empty">empty</a> :: <a href="Distribution-Compat-Graph.html#t:IsNode">IsNode</a> a =&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a</li><li class="src short"><a href="#v:insert">insert</a> :: <a href="Distribution-Compat-Graph.html#t:IsNode">IsNode</a> a =&gt; a -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a</li><li class="src short"><a href="#v:deleteKey">deleteKey</a> :: <a href="Distribution-Compat-Graph.html#t:IsNode">IsNode</a> a =&gt; <a href="Distribution-Compat-Graph.html#t:Key">Key</a> a -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a</li><li class="src short"><a href="#v:deleteLookup">deleteLookup</a> :: <a href="Distribution-Compat-Graph.html#t:IsNode">IsNode</a> a =&gt; <a href="Distribution-Compat-Graph.html#t:Key">Key</a> a -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Maybe.html#t:Maybe">Maybe</a> a, <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a)</li><li class="src short"><a href="#v:unionLeft">unionLeft</a> :: <a href="Distribution-Compat-Graph.html#t:IsNode">IsNode</a> a =&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a</li><li class="src short"><a href="#v:unionRight">unionRight</a> :: <a href="Distribution-Compat-Graph.html#t:IsNode">IsNode</a> a =&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a</li><li class="src short"><a href="#v:stronglyConnComp">stronglyConnComp</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; [<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> a]</li><li class="src short"><span class="keyword">data</span> <a href="#t:SCC">SCC</a> vertex :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a><ul class="subs"><li>= <a href="#v:AcyclicSCC">AcyclicSCC</a> vertex</li><li>| <a href="#v:CyclicSCC">CyclicSCC</a> [vertex]</li></ul></li><li class="src short"><a href="#v:cycles">cycles</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; [[a]]</li><li class="src short"><a href="#v:broken">broken</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; [(a, [<a href="Distribution-Compat-Graph.html#t:Key">Key</a> a])]</li><li class="src short"><a href="#v:neighbors">neighbors</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="Distribution-Compat-Graph.html#t:Key">Key</a> a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Maybe.html#t:Maybe">Maybe</a> [a]</li><li class="src short"><a href="#v:revNeighbors">revNeighbors</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="Distribution-Compat-Graph.html#t:Key">Key</a> a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Maybe.html#t:Maybe">Maybe</a> [a]</li><li class="src short"><a href="#v:closure">closure</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; [<a href="Distribution-Compat-Graph.html#t:Key">Key</a> a] -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Maybe.html#t:Maybe">Maybe</a> [a]</li><li class="src short"><a href="#v:revClosure">revClosure</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; [<a href="Distribution-Compat-Graph.html#t:Key">Key</a> a] -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Maybe.html#t:Maybe">Maybe</a> [a]</li><li class="src short"><a href="#v:topSort">topSort</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; [a]</li><li class="src short"><a href="#v:revTopSort">revTopSort</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; [a]</li><li class="src short"><a href="#v:toMap">toMap</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="Distribution-Compat-Prelude-Internal.html#t:Map">Map</a> (<a href="Distribution-Compat-Graph.html#t:Key">Key</a> a) a</li><li class="src short"><a href="#v:fromDistinctList">fromDistinctList</a> :: (<a href="Distribution-Compat-Graph.html#t:IsNode">IsNode</a> a, <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-Show.html#t:Show">Show</a> (<a href="Distribution-Compat-Graph.html#t:Key">Key</a> a)) =&gt; [a] -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a</li><li class="src short"><a href="#v:toList">toList</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; [a]</li><li class="src short"><a href="#v:keys">keys</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; [<a href="Distribution-Compat-Graph.html#t:Key">Key</a> a]</li><li class="src short"><a href="#v:keysSet">keysSet</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/containers-0.5.10.2/Data-Set-Internal.html#t:Set">Set</a> (<a href="Distribution-Compat-Graph.html#t:Key">Key</a> a)</li><li class="src short"><a href="#v:toGraph">toGraph</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/containers-0.5.10.2/Data-Graph.html#t:Graph">Graph</a>, <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/containers-0.5.10.2/Data-Graph.html#t:Vertex">Vertex</a> -&gt; a, <a href="Distribution-Compat-Graph.html#t:Key">Key</a> a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/containers-0.5.10.2/Data-Graph.html#t:Vertex">Vertex</a>)</li><li class="src short"><span class="keyword">data</span> <a href="#t:Node">Node</a> k a = <a href="#v:N">N</a> a k [k]</li><li class="src short"><a href="#v:nodeValue">nodeValue</a> :: <a href="Distribution-Compat-Graph.html#t:Node">Node</a> k a -&gt; a</li></ul></div><div id="interface"><h1 id="g:1">Graph type</h1><div class="top"><p class="src"><span class="keyword">data</span> <a id="t:Graph" class="def">Graph</a> a <a href="#t:Graph" class="selflink">#</a></p><div class="doc"><p>A graph of nodes <code>a</code>.  The nodes are expected to have instance
 of class <code><a href="Distribution-Compat-Graph.html#t:IsNode">IsNode</a></code>.</p></div><div class="subs instances"><p id="control.i:Graph" class="caption collapser" onclick="toggleSection('i:Graph')">Instances</p><div id="section.i:Graph" class="show"><table><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:Graph:Foldable:1" class="instance expander" onclick="toggleSection('i:id:Graph:Foldable:1')"></span> <a href="Distribution-Compat-Prelude-Internal.html#t:Foldable">Foldable</a> <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a></span> <a href="#t:Graph" class="selflink">#</a></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div id="section.i:id:Graph:Foldable:1" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:fold">fold</a> :: <a href="Distribution-Compat-Semigroup.html#t:Monoid">Monoid</a> m =&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> m -&gt; m <a href="#v:fold" class="selflink">#</a></p><p class="src"><a href="#v:foldMap">foldMap</a> :: <a href="Distribution-Compat-Semigroup.html#t:Monoid">Monoid</a> m =&gt; (a -&gt; m) -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; m <a href="#v:foldMap" class="selflink">#</a></p><p class="src"><a href="#v:foldr">foldr</a> :: (a -&gt; b -&gt; b) -&gt; b -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; b <a href="#v:foldr" class="selflink">#</a></p><p class="src"><a href="#v:foldr-39-">foldr'</a> :: (a -&gt; b -&gt; b) -&gt; b -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; b <a href="#v:foldr-39-" class="selflink">#</a></p><p class="src"><a href="#v:foldl">foldl</a> :: (b -&gt; a -&gt; b) -&gt; b -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; b <a href="#v:foldl" class="selflink">#</a></p><p class="src"><a href="#v:foldl-39-">foldl'</a> :: (b -&gt; a -&gt; b) -&gt; b -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; b <a href="#v:foldl-39-" class="selflink">#</a></p><p class="src"><a href="#v:foldr1">foldr1</a> :: (a -&gt; a -&gt; a) -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; a <a href="#v:foldr1" class="selflink">#</a></p><p class="src"><a href="#v:foldl1">foldl1</a> :: (a -&gt; a -&gt; a) -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; a <a href="#v:foldl1" class="selflink">#</a></p><p class="src"><a href="#v:toList">toList</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; [a] <a href="#v:toList" class="selflink">#</a></p><p class="src"><a href="#v:null">null</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Bool.html#t:Bool">Bool</a> <a href="#v:null" class="selflink">#</a></p><p class="src"><a href="#v:length">length</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Int.html#t:Int">Int</a> <a href="#v:length" class="selflink">#</a></p><p class="src"><a href="#v:elem">elem</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Eq.html#t:Eq">Eq</a> a =&gt; a -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Bool.html#t:Bool">Bool</a> <a href="#v:elem" class="selflink">#</a></p><p class="src"><a href="#v:maximum">maximum</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Ord.html#t:Ord">Ord</a> a =&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; a <a href="#v:maximum" class="selflink">#</a></p><p class="src"><a href="#v:minimum">minimum</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Ord.html#t:Ord">Ord</a> a =&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; a <a href="#v:minimum" class="selflink">#</a></p><p class="src"><a href="#v:sum">sum</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Prelude.html#t:Num">Num</a> a =&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; a <a href="#v:sum" class="selflink">#</a></p><p class="src"><a href="#v:product">product</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Prelude.html#t:Num">Num</a> a =&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; a <a href="#v:product" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:Graph:Eq:2" class="instance expander" onclick="toggleSection('i:id:Graph:Eq:2')"></span> (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Eq.html#t:Eq">Eq</a> (<a href="Distribution-Compat-Graph.html#t:Key">Key</a> a), <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Eq.html#t:Eq">Eq</a> a) =&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Eq.html#t:Eq">Eq</a> (<a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a)</span> <a href="#t:Graph" class="selflink">#</a></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div id="section.i:id:Graph:Eq:2" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:-61--61-">(==)</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Bool.html#t:Bool">Bool</a> <a href="#v:-61--61-" class="selflink">#</a></p><p class="src"><a href="#v:-47--61-">(/=)</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Bool.html#t:Bool">Bool</a> <a href="#v:-47--61-" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:Graph:Read:3" class="instance expander" onclick="toggleSection('i:id:Graph:Read:3')"></span> (<a href="Distribution-Compat-Graph.html#t:IsNode">IsNode</a> a, <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-Read.html#t:Read">Read</a> a, <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-Show.html#t:Show">Show</a> (<a href="Distribution-Compat-Graph.html#t:Key">Key</a> a)) =&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-Read.html#t:Read">Read</a> (<a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a)</span> <a href="#t:Graph" class="selflink">#</a></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div id="section.i:id:Graph:Read:3" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:readsPrec">readsPrec</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="Distribution-Compat-ReadP.html#t:ReadS">ReadS</a> (<a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a) <a href="#v:readsPrec" class="selflink">#</a></p><p class="src"><a href="#v:readList">readList</a> :: <a href="Distribution-Compat-ReadP.html#t:ReadS">ReadS</a> [<a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a] <a href="#v:readList" class="selflink">#</a></p><p class="src"><a href="#v:readPrec">readPrec</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-ParserCombinators-ReadPrec.html#t:ReadPrec">ReadPrec</a> (<a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a) <a href="#v:readPrec" class="selflink">#</a></p><p class="src"><a href="#v:readListPrec">readListPrec</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-ParserCombinators-ReadPrec.html#t:ReadPrec">ReadPrec</a> [<a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a] <a href="#v:readListPrec" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:Graph:Show:4" class="instance expander" onclick="toggleSection('i:id:Graph:Show:4')"></span> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-Show.html#t:Show">Show</a> a =&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-Show.html#t:Show">Show</a> (<a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a)</span> <a href="#t:Graph" class="selflink">#</a></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div id="section.i:id:Graph:Show:4" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:showsPrec">showsPrec</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-Show.html#t:ShowS">ShowS</a> <a href="#v:showsPrec" class="selflink">#</a></p><p class="src"><a href="#v:show">show</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-String.html#t:String">String</a> <a href="#v:show" class="selflink">#</a></p><p class="src"><a href="#v:showList">showList</a> :: [<a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a] -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-Show.html#t:ShowS">ShowS</a> <a href="#v:showList" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:Graph:Binary:5" class="instance expander" onclick="toggleSection('i:id:Graph:Binary:5')"></span> (<a href="Distribution-Compat-Graph.html#t:IsNode">IsNode</a> a, <a href="Distribution-Compat-Prelude-Internal.html#t:Binary">Binary</a> a, <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-Show.html#t:Show">Show</a> (<a href="Distribution-Compat-Graph.html#t:Key">Key</a> a)) =&gt; <a href="Distribution-Compat-Prelude-Internal.html#t:Binary">Binary</a> (<a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a)</span> <a href="#t:Graph" class="selflink">#</a></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div id="section.i:id:Graph:Binary:5" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:put">put</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/binary-0.8.5.1/Data-Binary-Put.html#t:Put">Put</a> <a href="#v:put" class="selflink">#</a></p><p class="src"><a href="#v:get">get</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/binary-0.8.5.1/Data-Binary-Get-Internal.html#t:Get">Get</a> (<a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a) <a href="#v:get" class="selflink">#</a></p><p class="src"><a href="#v:putList">putList</a> :: [<a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a] -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/binary-0.8.5.1/Data-Binary-Put.html#t:Put">Put</a> <a href="#v:putList" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:Graph:NFData:6" class="instance expander" onclick="toggleSection('i:id:Graph:NFData:6')"></span> (<a href="Distribution-Compat-Prelude-Internal.html#t:NFData">NFData</a> a, <a href="Distribution-Compat-Prelude-Internal.html#t:NFData">NFData</a> (<a href="Distribution-Compat-Graph.html#t:Key">Key</a> a)) =&gt; <a href="Distribution-Compat-Prelude-Internal.html#t:NFData">NFData</a> (<a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a)</span> <a href="#t:Graph" class="selflink">#</a></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div id="section.i:id:Graph:NFData:6" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:rnf">rnf</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; () <a href="#v:rnf" class="selflink">#</a></p></div></div></td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">class</span> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Ord.html#t:Ord">Ord</a> (<a href="Distribution-Compat-Graph.html#t:Key">Key</a> a) =&gt; <a id="t:IsNode" class="def">IsNode</a> a <span class="keyword">where</span> <a href="#t:IsNode" class="selflink">#</a></p><div class="doc"><p>The <code><a href="Distribution-Compat-Graph.html#t:IsNode">IsNode</a></code> class is used for datatypes which represent directed
 graph nodes.  A node of type <code>a</code> is associated with some unique key of
 type <code><code><a href="Distribution-Compat-Graph.html#t:Key">Key</a></code> a</code>; given a node we can determine its key (<code><a href="Distribution-Compat-Graph.html#v:nodeKey">nodeKey</a></code>)
 and the keys of its neighbors (<code><a href="Distribution-Compat-Graph.html#v:nodeNeighbors">nodeNeighbors</a></code>).</p></div><div class="subs minimal"><p class="caption">Minimal complete definition</p><p class="src"><a href="Distribution-Compat-Graph.html#v:nodeKey">nodeKey</a>, <a href="Distribution-Compat-Graph.html#v:nodeNeighbors">nodeNeighbors</a></p></div><div class="subs associated-types"><p class="caption">Associated Types</p><p class="src"><span class="keyword">type</span> <a id="t:Key" class="def">Key</a> a :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> <a href="#t:Key" class="selflink">#</a></p></div><div class="subs methods"><p class="caption">Methods</p><p class="src"><a id="v:nodeKey" class="def">nodeKey</a> :: a -&gt; <a href="Distribution-Compat-Graph.html#t:Key">Key</a> a <a href="#v:nodeKey" class="selflink">#</a></p><p class="src"><a id="v:nodeNeighbors" class="def">nodeNeighbors</a> :: a -&gt; [<a href="Distribution-Compat-Graph.html#t:Key">Key</a> a] <a href="#v:nodeNeighbors" class="selflink">#</a></p></div><div class="subs instances"><p id="control.i:IsNode" class="caption collapser" onclick="toggleSection('i:IsNode')">Instances</p><div id="section.i:IsNode" class="show"><table><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:ic:IsNode:IsNode:1" class="instance expander" onclick="toggleSection('i:ic:IsNode:IsNode:1')"></span> <a href="Distribution-Compat-Graph.html#t:IsNode">IsNode</a> <a href="Distribution-InstalledPackageInfo.html#t:InstalledPackageInfo">InstalledPackageInfo</a></span> <a href="#t:IsNode" class="selflink">#</a></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div id="section.i:ic:IsNode:IsNode:1" class="inst-details hide"><div class="subs associated-types"><p class="caption">Associated Types</p><p class="src"><span class="keyword">type</span> <a href="Distribution-Compat-Graph.html#t:Key">Key</a> <a href="Distribution-InstalledPackageInfo.html#t:InstalledPackageInfo">InstalledPackageInfo</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> <a href="#t:Key" class="selflink">#</a></p></div> <div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:nodeKey">nodeKey</a> :: <a href="Distribution-InstalledPackageInfo.html#t:InstalledPackageInfo">InstalledPackageInfo</a> -&gt; <a href="Distribution-Compat-Graph.html#t:Key">Key</a> <a href="Distribution-InstalledPackageInfo.html#t:InstalledPackageInfo">InstalledPackageInfo</a> <a href="#v:nodeKey" class="selflink">#</a></p><p class="src"><a href="#v:nodeNeighbors">nodeNeighbors</a> :: <a href="Distribution-InstalledPackageInfo.html#t:InstalledPackageInfo">InstalledPackageInfo</a> -&gt; [<a href="Distribution-Compat-Graph.html#t:Key">Key</a> <a href="Distribution-InstalledPackageInfo.html#t:InstalledPackageInfo">InstalledPackageInfo</a>] <a href="#v:nodeNeighbors" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:ic:IsNode:IsNode:2" class="instance expander" onclick="toggleSection('i:ic:IsNode:IsNode:2')"></span> <a href="Distribution-Compat-Graph.html#t:IsNode">IsNode</a> <a href="Distribution-Types-ComponentLocalBuildInfo.html#t:ComponentLocalBuildInfo">ComponentLocalBuildInfo</a></span> <a href="#t:IsNode" class="selflink">#</a></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div id="section.i:ic:IsNode:IsNode:2" class="inst-details hide"><div class="subs associated-types"><p class="caption">Associated Types</p><p class="src"><span class="keyword">type</span> <a href="Distribution-Compat-Graph.html#t:Key">Key</a> <a href="Distribution-Types-ComponentLocalBuildInfo.html#t:ComponentLocalBuildInfo">ComponentLocalBuildInfo</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> <a href="#t:Key" class="selflink">#</a></p></div> <div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:nodeKey">nodeKey</a> :: <a href="Distribution-Types-ComponentLocalBuildInfo.html#t:ComponentLocalBuildInfo">ComponentLocalBuildInfo</a> -&gt; <a href="Distribution-Compat-Graph.html#t:Key">Key</a> <a href="Distribution-Types-ComponentLocalBuildInfo.html#t:ComponentLocalBuildInfo">ComponentLocalBuildInfo</a> <a href="#v:nodeKey" class="selflink">#</a></p><p class="src"><a href="#v:nodeNeighbors">nodeNeighbors</a> :: <a href="Distribution-Types-ComponentLocalBuildInfo.html#t:ComponentLocalBuildInfo">ComponentLocalBuildInfo</a> -&gt; [<a href="Distribution-Compat-Graph.html#t:Key">Key</a> <a href="Distribution-Types-ComponentLocalBuildInfo.html#t:ComponentLocalBuildInfo">ComponentLocalBuildInfo</a>] <a href="#v:nodeNeighbors" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:ic:IsNode:IsNode:3" class="instance expander" onclick="toggleSection('i:ic:IsNode:IsNode:3')"></span> <a href="Distribution-Compat-Graph.html#t:IsNode">IsNode</a> <a href="Distribution-Types-TargetInfo.html#t:TargetInfo">TargetInfo</a></span> <a href="#t:IsNode" class="selflink">#</a></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div id="section.i:ic:IsNode:IsNode:3" class="inst-details hide"><div class="subs associated-types"><p class="caption">Associated Types</p><p class="src"><span class="keyword">type</span> <a href="Distribution-Compat-Graph.html#t:Key">Key</a> <a href="Distribution-Types-TargetInfo.html#t:TargetInfo">TargetInfo</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> <a href="#t:Key" class="selflink">#</a></p></div> <div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:nodeKey">nodeKey</a> :: <a href="Distribution-Types-TargetInfo.html#t:TargetInfo">TargetInfo</a> -&gt; <a href="Distribution-Compat-Graph.html#t:Key">Key</a> <a href="Distribution-Types-TargetInfo.html#t:TargetInfo">TargetInfo</a> <a href="#v:nodeKey" class="selflink">#</a></p><p class="src"><a href="#v:nodeNeighbors">nodeNeighbors</a> :: <a href="Distribution-Types-TargetInfo.html#t:TargetInfo">TargetInfo</a> -&gt; [<a href="Distribution-Compat-Graph.html#t:Key">Key</a> <a href="Distribution-Types-TargetInfo.html#t:TargetInfo">TargetInfo</a>] <a href="#v:nodeNeighbors" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:ic:IsNode:IsNode:4" class="instance expander" onclick="toggleSection('i:ic:IsNode:IsNode:4')"></span> (<a href="Distribution-Compat-Graph.html#t:IsNode">IsNode</a> a, <a href="Distribution-Compat-Graph.html#t:IsNode">IsNode</a> b, (~) <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> (<a href="Distribution-Compat-Graph.html#t:Key">Key</a> a) (<a href="Distribution-Compat-Graph.html#t:Key">Key</a> b)) =&gt; <a href="Distribution-Compat-Graph.html#t:IsNode">IsNode</a> (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Either.html#t:Either">Either</a> a b)</span> <a href="#t:IsNode" class="selflink">#</a></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div id="section.i:ic:IsNode:IsNode:4" class="inst-details hide"><div class="subs associated-types"><p class="caption">Associated Types</p><p class="src"><span class="keyword">type</span> <a href="Distribution-Compat-Graph.html#t:Key">Key</a> (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Either.html#t:Either">Either</a> a b) :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> <a href="#t:Key" class="selflink">#</a></p></div> <div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:nodeKey">nodeKey</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Either.html#t:Either">Either</a> a b -&gt; <a href="Distribution-Compat-Graph.html#t:Key">Key</a> (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Either.html#t:Either">Either</a> a b) <a href="#v:nodeKey" class="selflink">#</a></p><p class="src"><a href="#v:nodeNeighbors">nodeNeighbors</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Either.html#t:Either">Either</a> a b -&gt; [<a href="Distribution-Compat-Graph.html#t:Key">Key</a> (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Either.html#t:Either">Either</a> a b)] <a href="#v:nodeNeighbors" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:ic:IsNode:IsNode:5" class="instance expander" onclick="toggleSection('i:ic:IsNode:IsNode:5')"></span> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Ord.html#t:Ord">Ord</a> k =&gt; <a href="Distribution-Compat-Graph.html#t:IsNode">IsNode</a> (<a href="Distribution-Compat-Graph.html#t:Node">Node</a> k a)</span> <a href="#t:IsNode" class="selflink">#</a></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div id="section.i:ic:IsNode:IsNode:5" class="inst-details hide"><div class="subs associated-types"><p class="caption">Associated Types</p><p class="src"><span class="keyword">type</span> <a href="Distribution-Compat-Graph.html#t:Key">Key</a> (<a href="Distribution-Compat-Graph.html#t:Node">Node</a> k a) :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> <a href="#t:Key" class="selflink">#</a></p></div> <div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:nodeKey">nodeKey</a> :: <a href="Distribution-Compat-Graph.html#t:Node">Node</a> k a -&gt; <a href="Distribution-Compat-Graph.html#t:Key">Key</a> (<a href="Distribution-Compat-Graph.html#t:Node">Node</a> k a) <a href="#v:nodeKey" class="selflink">#</a></p><p class="src"><a href="#v:nodeNeighbors">nodeNeighbors</a> :: <a href="Distribution-Compat-Graph.html#t:Node">Node</a> k a -&gt; [<a href="Distribution-Compat-Graph.html#t:Key">Key</a> (<a href="Distribution-Compat-Graph.html#t:Node">Node</a> k a)] <a href="#v:nodeNeighbors" class="selflink">#</a></p></div></div></td></tr></table></div></div></div><h1 id="g:2">Query</h1><div class="top"><p class="src"><a id="v:null" class="def">null</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Bool.html#t:Bool">Bool</a> <a href="#v:null" class="selflink">#</a></p><div class="doc"><p><em>O(1)</em>. Is the graph empty?</p></div></div><div class="top"><p class="src"><a id="v:size" class="def">size</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Int.html#t:Int">Int</a> <a href="#v:size" class="selflink">#</a></p><div class="doc"><p><em>O(1)</em>. The number of nodes in the graph.</p></div></div><div class="top"><p class="src"><a id="v:member" class="def">member</a> :: <a href="Distribution-Compat-Graph.html#t:IsNode">IsNode</a> a =&gt; <a href="Distribution-Compat-Graph.html#t:Key">Key</a> a -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Bool.html#t:Bool">Bool</a> <a href="#v:member" class="selflink">#</a></p><div class="doc"><p><em>O(log V)</em>. Check if the key is in the graph.</p></div></div><div class="top"><p class="src"><a id="v:lookup" class="def">lookup</a> :: <a href="Distribution-Compat-Graph.html#t:IsNode">IsNode</a> a =&gt; <a href="Distribution-Compat-Graph.html#t:Key">Key</a> a -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Maybe.html#t:Maybe">Maybe</a> a <a href="#v:lookup" class="selflink">#</a></p><div class="doc"><p><em>O(log V)</em>. Lookup the node at a key in the graph.</p></div></div><h1 id="g:3">Construction</h1><div class="top"><p class="src"><a id="v:empty" class="def">empty</a> :: <a href="Distribution-Compat-Graph.html#t:IsNode">IsNode</a> a =&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a <a href="#v:empty" class="selflink">#</a></p><div class="doc"><p><em>O(1)</em>. The empty graph.</p></div></div><div class="top"><p class="src"><a id="v:insert" class="def">insert</a> :: <a href="Distribution-Compat-Graph.html#t:IsNode">IsNode</a> a =&gt; a -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a <a href="#v:insert" class="selflink">#</a></p><div class="doc"><p><em>O(log V)</em>. Insert a node into a graph.</p></div></div><div class="top"><p class="src"><a id="v:deleteKey" class="def">deleteKey</a> :: <a href="Distribution-Compat-Graph.html#t:IsNode">IsNode</a> a =&gt; <a href="Distribution-Compat-Graph.html#t:Key">Key</a> a -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a <a href="#v:deleteKey" class="selflink">#</a></p><div class="doc"><p><em>O(log V)</em>. Delete the node at a key from the graph.</p></div></div><div class="top"><p class="src"><a id="v:deleteLookup" class="def">deleteLookup</a> :: <a href="Distribution-Compat-Graph.html#t:IsNode">IsNode</a> a =&gt; <a href="Distribution-Compat-Graph.html#t:Key">Key</a> a -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Maybe.html#t:Maybe">Maybe</a> a, <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a) <a href="#v:deleteLookup" class="selflink">#</a></p><div class="doc"><p><em>O(log V)</em>. Lookup and delete.  This function returns the deleted
 value if it existed.</p></div></div><h1 id="g:4">Combine</h1><div class="top"><p class="src"><a id="v:unionLeft" class="def">unionLeft</a> :: <a href="Distribution-Compat-Graph.html#t:IsNode">IsNode</a> a =&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a <a href="#v:unionLeft" class="selflink">#</a></p><div class="doc"><p><em>O(V + V')</em>. Left-biased union, preferring entries from
 the first map when conflicts occur.</p></div></div><div class="top"><p class="src"><a id="v:unionRight" class="def">unionRight</a> :: <a href="Distribution-Compat-Graph.html#t:IsNode">IsNode</a> a =&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a <a href="#v:unionRight" class="selflink">#</a></p><div class="doc"><p><em>O(V + V')</em>. Right-biased union, preferring entries
 from the second map when conflicts occur.
 <code><code><a href="Distribution-Compat-Graph.html#v:nodeKey">nodeKey</a></code> x = <code><a href="Distribution-Compat-Graph.html#v:nodeKey">nodeKey</a></code> (f x)</code>.</p></div></div><h1 id="g:5">Graph algorithms</h1><div class="top"><p class="src"><a id="v:stronglyConnComp" class="def">stronglyConnComp</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; [<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> a] <a href="#v:stronglyConnComp" class="selflink">#</a></p><div class="doc"><p><em>&#937;(V + E)</em>. Compute the strongly connected components of a graph.
 Requires amortized construction of graph.</p></div></div><div class="top"><p class="src"><span class="keyword">data</span> <a id="t:SCC" class="def">SCC</a> vertex :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> <a href="#t:SCC" class="selflink">#</a></p><div class="doc"><p>Strongly connected component.</p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a id="v:AcyclicSCC" class="def">AcyclicSCC</a> vertex</td><td class="doc"><p>A single vertex that is not
 in any cycle.</p></td></tr><tr><td class="src"><a id="v:CyclicSCC" class="def">CyclicSCC</a> [vertex]</td><td class="doc"><p>A maximal set of mutually
 reachable vertices.</p></td></tr></table></div><div class="subs instances"><p id="control.i:SCC" class="caption collapser" onclick="toggleSection('i:SCC')">Instances</p><div id="section.i:SCC" class="show"><table><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:SCC:Functor:1" class="instance expander" onclick="toggleSection('i:id:SCC:Functor:1')"></span> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Functor.html#t:Functor">Functor</a> <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a></span></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div id="section.i:id:SCC:Functor:1" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:fmap">fmap</a> :: (a -&gt; b) -&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> a -&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> b <a href="#v:fmap" class="selflink">#</a></p><p class="src"><a href="#v:-60--36-">(&lt;$)</a> :: a -&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> b -&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> a <a href="#v:-60--36-" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:SCC:Foldable:2" class="instance expander" onclick="toggleSection('i:id:SCC:Foldable:2')"></span> <a href="Distribution-Compat-Prelude-Internal.html#t:Foldable">Foldable</a> <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a></span></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div id="section.i:id:SCC:Foldable:2" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:fold">fold</a> :: <a href="Distribution-Compat-Semigroup.html#t:Monoid">Monoid</a> m =&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> m -&gt; m <a href="#v:fold" class="selflink">#</a></p><p class="src"><a href="#v:foldMap">foldMap</a> :: <a href="Distribution-Compat-Semigroup.html#t:Monoid">Monoid</a> m =&gt; (a -&gt; m) -&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> a -&gt; m <a href="#v:foldMap" class="selflink">#</a></p><p class="src"><a href="#v:foldr">foldr</a> :: (a -&gt; b -&gt; b) -&gt; b -&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> a -&gt; b <a href="#v:foldr" class="selflink">#</a></p><p class="src"><a href="#v:foldr-39-">foldr'</a> :: (a -&gt; b -&gt; b) -&gt; b -&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> a -&gt; b <a href="#v:foldr-39-" class="selflink">#</a></p><p class="src"><a href="#v:foldl">foldl</a> :: (b -&gt; a -&gt; b) -&gt; b -&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> a -&gt; b <a href="#v:foldl" class="selflink">#</a></p><p class="src"><a href="#v:foldl-39-">foldl'</a> :: (b -&gt; a -&gt; b) -&gt; b -&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> a -&gt; b <a href="#v:foldl-39-" class="selflink">#</a></p><p class="src"><a href="#v:foldr1">foldr1</a> :: (a -&gt; a -&gt; a) -&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> a -&gt; a <a href="#v:foldr1" class="selflink">#</a></p><p class="src"><a href="#v:foldl1">foldl1</a> :: (a -&gt; a -&gt; a) -&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> a -&gt; a <a href="#v:foldl1" class="selflink">#</a></p><p class="src"><a href="#v:toList">toList</a> :: <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> a -&gt; [a] <a href="#v:toList" class="selflink">#</a></p><p class="src"><a href="#v:null">null</a> :: <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Bool.html#t:Bool">Bool</a> <a href="#v:null" class="selflink">#</a></p><p class="src"><a href="#v:length">length</a> :: <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Int.html#t:Int">Int</a> <a href="#v:length" class="selflink">#</a></p><p class="src"><a href="#v:elem">elem</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Eq.html#t:Eq">Eq</a> a =&gt; a -&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Bool.html#t:Bool">Bool</a> <a href="#v:elem" class="selflink">#</a></p><p class="src"><a href="#v:maximum">maximum</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Ord.html#t:Ord">Ord</a> a =&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> a -&gt; a <a href="#v:maximum" class="selflink">#</a></p><p class="src"><a href="#v:minimum">minimum</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Ord.html#t:Ord">Ord</a> a =&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> a -&gt; a <a href="#v:minimum" class="selflink">#</a></p><p class="src"><a href="#v:sum">sum</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Prelude.html#t:Num">Num</a> a =&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> a -&gt; a <a href="#v:sum" class="selflink">#</a></p><p class="src"><a href="#v:product">product</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Prelude.html#t:Num">Num</a> a =&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> a -&gt; a <a href="#v:product" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:SCC:Traversable:3" class="instance expander" onclick="toggleSection('i:id:SCC:Traversable:3')"></span> <a href="Distribution-Compat-Prelude-Internal.html#t:Traversable">Traversable</a> <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a></span></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div id="section.i:id:SCC:Traversable:3" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:traverse">traverse</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Control-Applicative.html#t:Applicative">Applicative</a> f =&gt; (a -&gt; f b) -&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> a -&gt; f (<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> b) <a href="#v:traverse" class="selflink">#</a></p><p class="src"><a href="#v:sequenceA">sequenceA</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Control-Applicative.html#t:Applicative">Applicative</a> f =&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> (f a) -&gt; f (<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> a) <a href="#v:sequenceA" class="selflink">#</a></p><p class="src"><a href="#v:mapM">mapM</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Control-Monad.html#t:Monad">Monad</a> m =&gt; (a -&gt; m b) -&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> a -&gt; m (<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> b) <a href="#v:mapM" class="selflink">#</a></p><p class="src"><a href="#v:sequence">sequence</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Control-Monad.html#t:Monad">Monad</a> m =&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> (m a) -&gt; m (<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> a) <a href="#v:sequence" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:SCC:Eq1:4" class="instance expander" onclick="toggleSection('i:id:SCC:Eq1:4')"></span> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Functor-Classes.html#t:Eq1">Eq1</a> <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a></span></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div id="section.i:id:SCC:Eq1:4" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:liftEq">liftEq</a> :: (a -&gt; b -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Bool.html#t:Bool">Bool</a>) -&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> a -&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> b -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Bool.html#t:Bool">Bool</a> <a href="#v:liftEq" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:SCC:Read1:5" class="instance expander" onclick="toggleSection('i:id:SCC:Read1:5')"></span> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Functor-Classes.html#t:Read1">Read1</a> <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a></span></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div id="section.i:id:SCC:Read1:5" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:liftReadsPrec">liftReadsPrec</a> :: (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="Distribution-Compat-ReadP.html#t:ReadS">ReadS</a> a) -&gt; <a href="Distribution-Compat-ReadP.html#t:ReadS">ReadS</a> [a] -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="Distribution-Compat-ReadP.html#t:ReadS">ReadS</a> (<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> a) <a href="#v:liftReadsPrec" class="selflink">#</a></p><p class="src"><a href="#v:liftReadList">liftReadList</a> :: (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="Distribution-Compat-ReadP.html#t:ReadS">ReadS</a> a) -&gt; <a href="Distribution-Compat-ReadP.html#t:ReadS">ReadS</a> [a] -&gt; <a href="Distribution-Compat-ReadP.html#t:ReadS">ReadS</a> [<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> a] <a href="#v:liftReadList" class="selflink">#</a></p><p class="src"><a href="#v:liftReadPrec">liftReadPrec</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-ParserCombinators-ReadPrec.html#t:ReadPrec">ReadPrec</a> a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-ParserCombinators-ReadPrec.html#t:ReadPrec">ReadPrec</a> [a] -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-ParserCombinators-ReadPrec.html#t:ReadPrec">ReadPrec</a> (<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> a) <a href="#v:liftReadPrec" class="selflink">#</a></p><p class="src"><a href="#v:liftReadListPrec">liftReadListPrec</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-ParserCombinators-ReadPrec.html#t:ReadPrec">ReadPrec</a> a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-ParserCombinators-ReadPrec.html#t:ReadPrec">ReadPrec</a> [a] -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-ParserCombinators-ReadPrec.html#t:ReadPrec">ReadPrec</a> [<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> a] <a href="#v:liftReadListPrec" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:SCC:Show1:6" class="instance expander" onclick="toggleSection('i:id:SCC:Show1:6')"></span> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Functor-Classes.html#t:Show1">Show1</a> <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a></span></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div id="section.i:id:SCC:Show1:6" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:liftShowsPrec">liftShowsPrec</a> :: (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Int.html#t:Int">Int</a> -&gt; a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-Show.html#t:ShowS">ShowS</a>) -&gt; ([a] -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-Show.html#t:ShowS">ShowS</a>) -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-Show.html#t:ShowS">ShowS</a> <a href="#v:liftShowsPrec" class="selflink">#</a></p><p class="src"><a href="#v:liftShowList">liftShowList</a> :: (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Int.html#t:Int">Int</a> -&gt; a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-Show.html#t:ShowS">ShowS</a>) -&gt; ([a] -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-Show.html#t:ShowS">ShowS</a>) -&gt; [<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> a] -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-Show.html#t:ShowS">ShowS</a> <a href="#v:liftShowList" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:SCC:Eq:7" class="instance expander" onclick="toggleSection('i:id:SCC:Eq:7')"></span> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Eq.html#t:Eq">Eq</a> vertex =&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Eq.html#t:Eq">Eq</a> (<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex)</span></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div id="section.i:id:SCC:Eq:7" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:-61--61-">(==)</a> :: <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex -&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Bool.html#t:Bool">Bool</a> <a href="#v:-61--61-" class="selflink">#</a></p><p class="src"><a href="#v:-47--61-">(/=)</a> :: <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex -&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Bool.html#t:Bool">Bool</a> <a href="#v:-47--61-" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:SCC:Data:8" class="instance expander" onclick="toggleSection('i:id:SCC:Data:8')"></span> <a href="Distribution-Compat-Prelude-Internal.html#t:Data">Data</a> vertex =&gt; <a href="Distribution-Compat-Prelude-Internal.html#t:Data">Data</a> (<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex)</span></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div id="section.i:id:SCC:Data:8" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:gfoldl">gfoldl</a> :: (<span class="keyword">forall</span> d b. <a href="Distribution-Compat-Prelude-Internal.html#t:Data">Data</a> d =&gt; c (d -&gt; b) -&gt; d -&gt; c b) -&gt; (<span class="keyword">forall</span> g. g -&gt; c g) -&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex -&gt; c (<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex) <a href="#v:gfoldl" class="selflink">#</a></p><p class="src"><a href="#v:gunfold">gunfold</a> :: (<span class="keyword">forall</span> b r. <a href="Distribution-Compat-Prelude-Internal.html#t:Data">Data</a> b =&gt; c (b -&gt; r) -&gt; c r) -&gt; (<span class="keyword">forall</span> r. r -&gt; c r) -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Data.html#t:Constr">Constr</a> -&gt; c (<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex) <a href="#v:gunfold" class="selflink">#</a></p><p class="src"><a href="#v:toConstr">toConstr</a> :: <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Data.html#t:Constr">Constr</a> <a href="#v:toConstr" class="selflink">#</a></p><p class="src"><a href="#v:dataTypeOf">dataTypeOf</a> :: <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Data.html#t:DataType">DataType</a> <a href="#v:dataTypeOf" class="selflink">#</a></p><p class="src"><a href="#v:dataCast1">dataCast1</a> :: <a href="Distribution-Compat-Prelude-Internal.html#t:Typeable">Typeable</a> (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a>) t =&gt; (<span class="keyword">forall</span> d. <a href="Distribution-Compat-Prelude-Internal.html#t:Data">Data</a> d =&gt; c (t d)) -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Maybe.html#t:Maybe">Maybe</a> (c (<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex)) <a href="#v:dataCast1" class="selflink">#</a></p><p class="src"><a href="#v:dataCast2">dataCast2</a> :: <a href="Distribution-Compat-Prelude-Internal.html#t:Typeable">Typeable</a> (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a>) t =&gt; (<span class="keyword">forall</span> d e. (<a href="Distribution-Compat-Prelude-Internal.html#t:Data">Data</a> d, <a href="Distribution-Compat-Prelude-Internal.html#t:Data">Data</a> e) =&gt; c (t d e)) -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Maybe.html#t:Maybe">Maybe</a> (c (<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex)) <a href="#v:dataCast2" class="selflink">#</a></p><p class="src"><a href="#v:gmapT">gmapT</a> :: (<span class="keyword">forall</span> b. <a href="Distribution-Compat-Prelude-Internal.html#t:Data">Data</a> b =&gt; b -&gt; b) -&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex -&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex <a href="#v:gmapT" class="selflink">#</a></p><p class="src"><a href="#v:gmapQl">gmapQl</a> :: (r -&gt; r' -&gt; r) -&gt; r -&gt; (<span class="keyword">forall</span> d. <a href="Distribution-Compat-Prelude-Internal.html#t:Data">Data</a> d =&gt; d -&gt; r') -&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex -&gt; r <a href="#v:gmapQl" class="selflink">#</a></p><p class="src"><a href="#v:gmapQr">gmapQr</a> :: (r' -&gt; r -&gt; r) -&gt; r -&gt; (<span class="keyword">forall</span> d. <a href="Distribution-Compat-Prelude-Internal.html#t:Data">Data</a> d =&gt; d -&gt; r') -&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex -&gt; r <a href="#v:gmapQr" class="selflink">#</a></p><p class="src"><a href="#v:gmapQ">gmapQ</a> :: (<span class="keyword">forall</span> d. <a href="Distribution-Compat-Prelude-Internal.html#t:Data">Data</a> d =&gt; d -&gt; u) -&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex -&gt; [u] <a href="#v:gmapQ" class="selflink">#</a></p><p class="src"><a href="#v:gmapQi">gmapQi</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Int.html#t:Int">Int</a> -&gt; (<span class="keyword">forall</span> d. <a href="Distribution-Compat-Prelude-Internal.html#t:Data">Data</a> d =&gt; d -&gt; u) -&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex -&gt; u <a href="#v:gmapQi" class="selflink">#</a></p><p class="src"><a href="#v:gmapM">gmapM</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Control-Monad.html#t:Monad">Monad</a> m =&gt; (<span class="keyword">forall</span> d. <a href="Distribution-Compat-Prelude-Internal.html#t:Data">Data</a> d =&gt; d -&gt; m d) -&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex -&gt; m (<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex) <a href="#v:gmapM" class="selflink">#</a></p><p class="src"><a href="#v:gmapMp">gmapMp</a> :: <a href="Distribution-Compat-Prelude-Internal.html#t:MonadPlus">MonadPlus</a> m =&gt; (<span class="keyword">forall</span> d. <a href="Distribution-Compat-Prelude-Internal.html#t:Data">Data</a> d =&gt; d -&gt; m d) -&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex -&gt; m (<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex) <a href="#v:gmapMp" class="selflink">#</a></p><p class="src"><a href="#v:gmapMo">gmapMo</a> :: <a href="Distribution-Compat-Prelude-Internal.html#t:MonadPlus">MonadPlus</a> m =&gt; (<span class="keyword">forall</span> d. <a href="Distribution-Compat-Prelude-Internal.html#t:Data">Data</a> d =&gt; d -&gt; m d) -&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex -&gt; m (<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex) <a href="#v:gmapMo" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:SCC:Read:9" class="instance expander" onclick="toggleSection('i:id:SCC:Read:9')"></span> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-Read.html#t:Read">Read</a> vertex =&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-Read.html#t:Read">Read</a> (<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex)</span></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div id="section.i:id:SCC:Read:9" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:readsPrec">readsPrec</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="Distribution-Compat-ReadP.html#t:ReadS">ReadS</a> (<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex) <a href="#v:readsPrec" class="selflink">#</a></p><p class="src"><a href="#v:readList">readList</a> :: <a href="Distribution-Compat-ReadP.html#t:ReadS">ReadS</a> [<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex] <a href="#v:readList" class="selflink">#</a></p><p class="src"><a href="#v:readPrec">readPrec</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-ParserCombinators-ReadPrec.html#t:ReadPrec">ReadPrec</a> (<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex) <a href="#v:readPrec" class="selflink">#</a></p><p class="src"><a href="#v:readListPrec">readListPrec</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-ParserCombinators-ReadPrec.html#t:ReadPrec">ReadPrec</a> [<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex] <a href="#v:readListPrec" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:SCC:Show:10" class="instance expander" onclick="toggleSection('i:id:SCC:Show:10')"></span> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-Show.html#t:Show">Show</a> vertex =&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-Show.html#t:Show">Show</a> (<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex)</span></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div id="section.i:id:SCC:Show:10" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:showsPrec">showsPrec</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-Show.html#t:ShowS">ShowS</a> <a href="#v:showsPrec" class="selflink">#</a></p><p class="src"><a href="#v:show">show</a> :: <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-String.html#t:String">String</a> <a href="#v:show" class="selflink">#</a></p><p class="src"><a href="#v:showList">showList</a> :: [<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex] -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-Show.html#t:ShowS">ShowS</a> <a href="#v:showList" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:SCC:Generic:11" class="instance expander" onclick="toggleSection('i:id:SCC:Generic:11')"></span> <a href="Distribution-Compat-Prelude-Internal.html#t:Generic">Generic</a> (<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex)</span></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div id="section.i:id:SCC:Generic:11" class="inst-details hide"><div class="subs associated-types"><p class="caption">Associated Types</p><p class="src"><span class="keyword">type</span> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#t:Rep">Rep</a> (<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex) :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> <a href="#t:Rep" class="selflink">#</a></p></div> <div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:from">from</a> :: <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#t:Rep">Rep</a> (<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex) x <a href="#v:from" class="selflink">#</a></p><p class="src"><a href="#v:to">to</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#t:Rep">Rep</a> (<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex) x -&gt; <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex <a href="#v:to" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:SCC:NFData:12" class="instance expander" onclick="toggleSection('i:id:SCC:NFData:12')"></span> <a href="Distribution-Compat-Prelude-Internal.html#t:NFData">NFData</a> a =&gt; <a href="Distribution-Compat-Prelude-Internal.html#t:NFData">NFData</a> (<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> a)</span></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div id="section.i:id:SCC:NFData:12" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:rnf">rnf</a> :: <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> a -&gt; () <a href="#v:rnf" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:SCC:Generic1:13" class="instance expander" onclick="toggleSection('i:id:SCC:Generic1:13')"></span> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#t:Generic1">Generic1</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a></span></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div id="section.i:id:SCC:Generic1:13" class="inst-details hide"><div class="subs associated-types"><p class="caption">Associated Types</p><p class="src"><span class="keyword">type</span> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#t:Rep1">Rep1</a> <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> (f :: <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a>) :: k -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> <a href="#t:Rep1" class="selflink">#</a></p></div> <div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:from1">from1</a> :: f a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#t:Rep1">Rep1</a> <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> f a <a href="#v:from1" class="selflink">#</a></p><p class="src"><a href="#v:to1">to1</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#t:Rep1">Rep1</a> <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> f a -&gt; f a <a href="#v:to1" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:SCC:Rep:14" class="instance expander" onclick="toggleSection('i:id:SCC:Rep:14')"></span> <span class="keyword">type</span> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#t:Rep">Rep</a> (<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex)</span></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div id="section.i:id:SCC:Rep:14" class="inst-details hide"><div class="src"><span class="keyword">type</span> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#t:Rep">Rep</a> (<a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> vertex) = <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#t:D1">D1</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#v:MetaData">MetaData</a> &quot;SCC&quot; &quot;Data.Graph&quot; &quot;containers-0.5.10.2&quot; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Bool.html#v:False">False</a>) (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#t::-43-:">(:+:)</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#t:C1">C1</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#v:MetaCons">MetaCons</a> &quot;AcyclicSCC&quot; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#v:PrefixI">PrefixI</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Bool.html#v:False">False</a>) (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#t:S1">S1</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#v:MetaSel">MetaSel</a> (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Maybe.html#v:Nothing">Nothing</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-TypeLits.html#t:Symbol">Symbol</a>) <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#v:NoSourceUnpackedness">NoSourceUnpackedness</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#v:NoSourceStrictness">NoSourceStrictness</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#v:DecidedLazy">DecidedLazy</a>) (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#t:Rec0">Rec0</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> vertex))) (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#t:C1">C1</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#v:MetaCons">MetaCons</a> &quot;CyclicSCC&quot; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#v:PrefixI">PrefixI</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Bool.html#v:False">False</a>) (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#t:S1">S1</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#v:MetaSel">MetaSel</a> (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Maybe.html#v:Nothing">Nothing</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-TypeLits.html#t:Symbol">Symbol</a>) <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#v:NoSourceUnpackedness">NoSourceUnpackedness</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#v:NoSourceStrictness">NoSourceStrictness</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#v:DecidedLazy">DecidedLazy</a>) (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#t:Rec0">Rec0</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> [vertex]))))</div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:SCC:Rep1:15" class="instance expander" onclick="toggleSection('i:id:SCC:Rep1:15')"></span> <span class="keyword">type</span> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#t:Rep1">Rep1</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a></span></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div id="section.i:id:SCC:Rep1:15" class="inst-details hide"><div class="src"><span class="keyword">type</span> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#t:Rep1">Rep1</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> <a href="Distribution-Compat-Graph.html#t:SCC">SCC</a> = <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#t:D1">D1</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#v:MetaData">MetaData</a> &quot;SCC&quot; &quot;Data.Graph&quot; &quot;containers-0.5.10.2&quot; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Bool.html#v:False">False</a>) (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#t::-43-:">(:+:)</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#t:C1">C1</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#v:MetaCons">MetaCons</a> &quot;AcyclicSCC&quot; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#v:PrefixI">PrefixI</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Bool.html#v:False">False</a>) (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#t:S1">S1</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#v:MetaSel">MetaSel</a> (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Maybe.html#v:Nothing">Nothing</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-TypeLits.html#t:Symbol">Symbol</a>) <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#v:NoSourceUnpackedness">NoSourceUnpackedness</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#v:NoSourceStrictness">NoSourceStrictness</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#v:DecidedLazy">DecidedLazy</a>) <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#t:Par1">Par1</a>)) (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#t:C1">C1</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#v:MetaCons">MetaCons</a> &quot;CyclicSCC&quot; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#v:PrefixI">PrefixI</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Bool.html#v:False">False</a>) (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#t:S1">S1</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#v:MetaSel">MetaSel</a> (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Maybe.html#v:Nothing">Nothing</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-TypeLits.html#t:Symbol">Symbol</a>) <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#v:NoSourceUnpackedness">NoSourceUnpackedness</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#v:NoSourceStrictness">NoSourceStrictness</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#v:DecidedLazy">DecidedLazy</a>) (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/GHC-Generics.html#t:Rec1">Rec1</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> []))))</div></div></td></tr></table></div></div></div><div class="top"><p class="src"><a id="v:cycles" class="def">cycles</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; [[a]] <a href="#v:cycles" class="selflink">#</a></p><div class="doc"><p><em>&#937;(V + E)</em>. Compute the cycles of a graph.
 Requires amortized construction of graph.</p></div></div><div class="top"><p class="src"><a id="v:broken" class="def">broken</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; [(a, [<a href="Distribution-Compat-Graph.html#t:Key">Key</a> a])] <a href="#v:broken" class="selflink">#</a></p><div class="doc"><p><em>O(1)</em>.  Return a list of nodes paired with their broken
 neighbors (i.e., neighbor keys which are not in the graph).
 Requires amortized construction of graph.</p></div></div><div class="top"><p class="src"><a id="v:neighbors" class="def">neighbors</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="Distribution-Compat-Graph.html#t:Key">Key</a> a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Maybe.html#t:Maybe">Maybe</a> [a] <a href="#v:neighbors" class="selflink">#</a></p><div class="doc"><p>Lookup the immediate neighbors from a key in the graph.
 Requires amortized construction of graph.</p></div></div><div class="top"><p class="src"><a id="v:revNeighbors" class="def">revNeighbors</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="Distribution-Compat-Graph.html#t:Key">Key</a> a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Maybe.html#t:Maybe">Maybe</a> [a] <a href="#v:revNeighbors" class="selflink">#</a></p><div class="doc"><p>Lookup the immediate reverse neighbors from a key in the graph.
 Requires amortized construction of graph.</p></div></div><div class="top"><p class="src"><a id="v:closure" class="def">closure</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; [<a href="Distribution-Compat-Graph.html#t:Key">Key</a> a] -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Maybe.html#t:Maybe">Maybe</a> [a] <a href="#v:closure" class="selflink">#</a></p><div class="doc"><p>Compute the subgraph which is the closure of some set of keys.
 Returns <code>Nothing</code> if one (or more) keys are not present in
 the graph.
 Requires amortized construction of graph.</p></div></div><div class="top"><p class="src"><a id="v:revClosure" class="def">revClosure</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; [<a href="Distribution-Compat-Graph.html#t:Key">Key</a> a] -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Maybe.html#t:Maybe">Maybe</a> [a] <a href="#v:revClosure" class="selflink">#</a></p><div class="doc"><p>Compute the reverse closure of a graph from some set
 of keys.  Returns <code>Nothing</code> if one (or more) keys are not present in
 the graph.
 Requires amortized construction of graph.</p></div></div><div class="top"><p class="src"><a id="v:topSort" class="def">topSort</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; [a] <a href="#v:topSort" class="selflink">#</a></p><div class="doc"><p>Topologically sort the nodes of a graph.
 Requires amortized construction of graph.</p></div></div><div class="top"><p class="src"><a id="v:revTopSort" class="def">revTopSort</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; [a] <a href="#v:revTopSort" class="selflink">#</a></p><div class="doc"><p>Reverse topologically sort the nodes of a graph.
 Requires amortized construction of graph.</p></div></div><h1 id="g:6">Conversions</h1><h2 id="g:7">Maps</h2><div class="top"><p class="src"><a id="v:toMap" class="def">toMap</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="Distribution-Compat-Prelude-Internal.html#t:Map">Map</a> (<a href="Distribution-Compat-Graph.html#t:Key">Key</a> a) a <a href="#v:toMap" class="selflink">#</a></p><div class="doc"><p><em>O(1)</em>. Convert a graph into a map from keys to nodes.
 The resulting map <code>m</code> is guaranteed to have the property that
 <code><code><a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Foldable.html#v:all">all</a></code> ((k,n) -&gt; k == <code><a href="Distribution-Compat-Graph.html#v:nodeKey">nodeKey</a></code> n) (<code><a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/containers-0.5.10.2/Data-Map.html#v:toList">toList</a></code> m)</code>.</p></div></div><h2 id="g:8">Lists</h2><div class="top"><p class="src"><a id="v:fromDistinctList" class="def">fromDistinctList</a> :: (<a href="Distribution-Compat-Graph.html#t:IsNode">IsNode</a> a, <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-Show.html#t:Show">Show</a> (<a href="Distribution-Compat-Graph.html#t:Key">Key</a> a)) =&gt; [a] -&gt; <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a <a href="#v:fromDistinctList" class="selflink">#</a></p><div class="doc"><p><em>O(V log V)</em>. Convert a list of nodes (with distinct keys) into a graph.</p></div></div><div class="top"><p class="src"><a id="v:toList" class="def">toList</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; [a] <a href="#v:toList" class="selflink">#</a></p><div class="doc"><p><em>O(V)</em>. Convert a graph into a list of nodes.</p></div></div><div class="top"><p class="src"><a id="v:keys" class="def">keys</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; [<a href="Distribution-Compat-Graph.html#t:Key">Key</a> a] <a href="#v:keys" class="selflink">#</a></p><div class="doc"><p><em>O(V)</em>. Convert a graph into a list of keys.</p></div></div><h2 id="g:9">Sets</h2><div class="top"><p class="src"><a id="v:keysSet" class="def">keysSet</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/containers-0.5.10.2/Data-Set-Internal.html#t:Set">Set</a> (<a href="Distribution-Compat-Graph.html#t:Key">Key</a> a) <a href="#v:keysSet" class="selflink">#</a></p><div class="doc"><p><em>O(V)</em>. Convert a graph into a set of keys.</p></div></div><h2 id="g:10">Graphs</h2><div class="top"><p class="src"><a id="v:toGraph" class="def">toGraph</a> :: <a href="Distribution-Compat-Graph.html#t:Graph">Graph</a> a -&gt; (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/containers-0.5.10.2/Data-Graph.html#t:Graph">Graph</a>, <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/containers-0.5.10.2/Data-Graph.html#t:Vertex">Vertex</a> -&gt; a, <a href="Distribution-Compat-Graph.html#t:Key">Key</a> a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/containers-0.5.10.2/Data-Graph.html#t:Vertex">Vertex</a>) <a href="#v:toGraph" class="selflink">#</a></p><div class="doc"><p><em>O(1)</em>. Convert a graph into a <code><a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/containers-0.5.10.2/Data-Graph.html#v:Graph">Graph</a></code>.
 Requires amortized construction of graph.</p></div></div><h1 id="g:11">Node type</h1><div class="top"><p class="src"><span class="keyword">data</span> <a id="t:Node" class="def">Node</a> k a <a href="#t:Node" class="selflink">#</a></p><div class="doc"><p>A simple, trivial data type which admits an <code><a href="Distribution-Compat-Graph.html#t:IsNode">IsNode</a></code> instance.</p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a id="v:N" class="def">N</a> a k [k]</td><td class="doc empty">&nbsp;</td></tr></table></div><div class="subs instances"><p id="control.i:Node" class="caption collapser" onclick="toggleSection('i:Node')">Instances</p><div id="section.i:Node" class="show"><table><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:Node:Functor:1" class="instance expander" onclick="toggleSection('i:id:Node:Functor:1')"></span> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Functor.html#t:Functor">Functor</a> (<a href="Distribution-Compat-Graph.html#t:Node">Node</a> k)</span> <a href="#t:Node" class="selflink">#</a></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div id="section.i:id:Node:Functor:1" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:fmap">fmap</a> :: (a -&gt; b) -&gt; <a href="Distribution-Compat-Graph.html#t:Node">Node</a> k a -&gt; <a href="Distribution-Compat-Graph.html#t:Node">Node</a> k b <a href="#v:fmap" class="selflink">#</a></p><p class="src"><a href="#v:-60--36-">(&lt;$)</a> :: a -&gt; <a href="Distribution-Compat-Graph.html#t:Node">Node</a> k b -&gt; <a href="Distribution-Compat-Graph.html#t:Node">Node</a> k a <a href="#v:-60--36-" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:Node:Eq:2" class="instance expander" onclick="toggleSection('i:id:Node:Eq:2')"></span> (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Eq.html#t:Eq">Eq</a> k, <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Eq.html#t:Eq">Eq</a> a) =&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Eq.html#t:Eq">Eq</a> (<a href="Distribution-Compat-Graph.html#t:Node">Node</a> k a)</span> <a href="#t:Node" class="selflink">#</a></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div id="section.i:id:Node:Eq:2" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:-61--61-">(==)</a> :: <a href="Distribution-Compat-Graph.html#t:Node">Node</a> k a -&gt; <a href="Distribution-Compat-Graph.html#t:Node">Node</a> k a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Bool.html#t:Bool">Bool</a> <a href="#v:-61--61-" class="selflink">#</a></p><p class="src"><a href="#v:-47--61-">(/=)</a> :: <a href="Distribution-Compat-Graph.html#t:Node">Node</a> k a -&gt; <a href="Distribution-Compat-Graph.html#t:Node">Node</a> k a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Bool.html#t:Bool">Bool</a> <a href="#v:-47--61-" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:Node:Show:3" class="instance expander" onclick="toggleSection('i:id:Node:Show:3')"></span> (<a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-Show.html#t:Show">Show</a> k, <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-Show.html#t:Show">Show</a> a) =&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-Show.html#t:Show">Show</a> (<a href="Distribution-Compat-Graph.html#t:Node">Node</a> k a)</span> <a href="#t:Node" class="selflink">#</a></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div id="section.i:id:Node:Show:3" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:showsPrec">showsPrec</a> :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="Distribution-Compat-Graph.html#t:Node">Node</a> k a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-Show.html#t:ShowS">ShowS</a> <a href="#v:showsPrec" class="selflink">#</a></p><p class="src"><a href="#v:show">show</a> :: <a href="Distribution-Compat-Graph.html#t:Node">Node</a> k a -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-String.html#t:String">String</a> <a href="#v:show" class="selflink">#</a></p><p class="src"><a href="#v:showList">showList</a> :: [<a href="Distribution-Compat-Graph.html#t:Node">Node</a> k a] -&gt; <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Text-Show.html#t:ShowS">ShowS</a> <a href="#v:showList" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:Node:IsNode:4" class="instance expander" onclick="toggleSection('i:id:Node:IsNode:4')"></span> <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Ord.html#t:Ord">Ord</a> k =&gt; <a href="Distribution-Compat-Graph.html#t:IsNode">IsNode</a> (<a href="Distribution-Compat-Graph.html#t:Node">Node</a> k a)</span> <a href="#t:Node" class="selflink">#</a></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div id="section.i:id:Node:IsNode:4" class="inst-details hide"><div class="subs associated-types"><p class="caption">Associated Types</p><p class="src"><span class="keyword">type</span> <a href="Distribution-Compat-Graph.html#t:Key">Key</a> (<a href="Distribution-Compat-Graph.html#t:Node">Node</a> k a) :: <a href="file:///opt/ghc/8.2.2/share/doc/ghc-8.2.2/html/libraries/base-4.10.1.0/Data-Kind.html#t:-42-">*</a> <a href="#t:Key" class="selflink">#</a></p></div> <div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:nodeKey">nodeKey</a> :: <a href="Distribution-Compat-Graph.html#t:Node">Node</a> k a -&gt; <a href="Distribution-Compat-Graph.html#t:Key">Key</a> (<a href="Distribution-Compat-Graph.html#t:Node">Node</a> k a) <a href="#v:nodeKey" class="selflink">#</a></p><p class="src"><a href="#v:nodeNeighbors">nodeNeighbors</a> :: <a href="Distribution-Compat-Graph.html#t:Node">Node</a> k a -&gt; [<a href="Distribution-Compat-Graph.html#t:Key">Key</a> (<a href="Distribution-Compat-Graph.html#t:Node">Node</a> k a)] <a href="#v:nodeNeighbors" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:Node:Key:5" class="instance expander" onclick="toggleSection('i:id:Node:Key:5')"></span> <span class="keyword">type</span> <a href="Distribution-Compat-Graph.html#t:Key">Key</a> (<a href="Distribution-Compat-Graph.html#t:Node">Node</a> k a)</span> <a href="#t:Node" class="selflink">#</a></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div id="section.i:id:Node:Key:5" class="inst-details hide"><div class="src"><span class="keyword">type</span> <a href="Distribution-Compat-Graph.html#t:Key">Key</a> (<a href="Distribution-Compat-Graph.html#t:Node">Node</a> k a) = k</div></div></td></tr></table></div></div></div><div class="top"><p class="src"><a id="v:nodeValue" class="def">nodeValue</a> :: <a href="Distribution-Compat-Graph.html#t:Node">Node</a> k a -&gt; a <a href="#v:nodeValue" class="selflink">#</a></p><div class="doc"><p>Get the value from a <code><a href="Distribution-Compat-Graph.html#t:Node">Node</a></code>.</p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.18.1</p></div></body></html>