mirror of
https://github.com/github/semantic.git
synced 2024-11-27 12:57:49 +03:00
Give a signature for findEdgeNamed.
This commit is contained in:
parent
3c9736763d
commit
47084da3d0
@ -173,6 +173,7 @@ parseNode o = do
|
||||
attrs <- edge A..: pack "attrs"
|
||||
f attrs
|
||||
pure (IntMap.! sink))
|
||||
findEdgeNamed :: (A.FromJSON a, Eq a) => a -> A.Parser (IntMap.IntMap rep -> rep)
|
||||
findEdgeNamed name = foldMap (resolveWith (\ attrs -> attrs A..: pack "type" >>= guard . (== name))) edges
|
||||
o A..: pack "attrs" >>= A.withObject "attrs" (\ attrs -> do
|
||||
ty <- attrs A..: pack "type"
|
||||
|
Loading…
Reference in New Issue
Block a user