mirror of
https://github.com/github/semantic.git
synced 2024-11-28 10:15:55 +03:00
Rewrite keysOfAlignedChildren in tacit style in hopes of finding an infinite loop.
This commit is contained in:
parent
79ef67e6e3
commit
6fb9383fb1
@ -228,9 +228,7 @@ toPrettyDiff elements = PrettyDiff sources (alignBranch id children ranges)
|
||||
children = toAlignedChildren elements
|
||||
|
||||
keysOfAlignedChildren :: [Join These (Range, [(String, Range)])] -> [String]
|
||||
keysOfAlignedChildren lines = do
|
||||
line <- lines
|
||||
these id id (++) (runJoin (fmap Prelude.fst . Prelude.snd <$> line))
|
||||
keysOfAlignedChildren lines = lines >>= these id id (++) . runJoin . fmap (fmap Prelude.fst . Prelude.snd)
|
||||
|
||||
instance Arbitrary BranchElement where
|
||||
arbitrary = oneof [ key >>= \ key -> Child key <$> joinTheseOf (contents key)
|
||||
|
Loading…
Reference in New Issue
Block a user