File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -204,15 +204,15 @@ order = noNodes
204
204
size :: (Graph gr ) => gr a b -> Int
205
205
size = length . labEdges
206
206
207
- -- | Fold a function over the graph.
207
+ -- | Fold a function over the graph by recursively calling 'match' .
208
208
ufold :: (Graph gr ) => (Context a b -> c -> c ) -> c -> gr a b -> c
209
209
ufold f u g
210
210
| isEmpty g = u
211
211
| otherwise = f c (ufold f u g')
212
212
where
213
213
(c,g') = matchAny g
214
214
215
- -- | Map a function over the graph.
215
+ -- | Map a function over the graph by recursively calling 'match' .
216
216
gmap :: (DynGraph gr ) => (Context a b -> Context c d ) -> gr a b -> gr c d
217
217
gmap f = ufold (\ c-> (f c& )) empty
218
218
{-# NOINLINE [0] gmap #-}
@@ -349,7 +349,7 @@ mkUGraph vs es = mkGraph (labUNodes vs) (labUEdges es)
349
349
labUNodes = map (flip (,) () )
350
350
351
351
-- | Build a graph out of the contexts for which the predicate is
352
- -- true .
352
+ -- satisfied by recursively calling 'match' .
353
353
gfiltermap :: DynGraph gr => (Context a b -> MContext c d ) -> gr a b -> gr c d
354
354
gfiltermap f = ufold (maybe id (&) . f) empty
355
355
You can’t perform that action at this time.
0 commit comments