mirror of
https://github.com/github/semantic.git
synced 2024-11-23 16:37:50 +03:00
Inline edgeNamed.
This commit is contained in:
parent
cc807c7b95
commit
b1660bf2b1
@ -168,6 +168,5 @@ parseNode o = do
|
||||
attrs <- edge A..: pack "attrs"
|
||||
f sink attrs)
|
||||
resolve = edge (const . pure . flip (IntMap.!))
|
||||
edgeNamed name sink attrs = attrs A..: pack "type" >>= guard . (== name) >> pure (IntMap.! sink)
|
||||
findEdgeNamed name = foldMap (edge (edgeNamed name)) edges
|
||||
findEdgeNamed name = foldMap (edge (\ sink attrs -> attrs A..: pack "type" >>= guard . (== name) >> pure (IntMap.! sink))) edges
|
||||
o A..: pack "attrs" >>= A.withObject "attrs" (fmap (index,) . parseType)
|
||||
|
Loading…
Reference in New Issue
Block a user