From 6eabdd06ebfaf822311b58721ee4eedd1b8e37a7 Mon Sep 17 00:00:00 2001 From: Rob Rix Date: Fri, 20 May 2016 21:50:41 -0400 Subject: [PATCH] Compute a pair of Sources from a list of child lines. --- test/AlignmentSpec.hs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/test/AlignmentSpec.hs b/test/AlignmentSpec.hs index 292833593..caf2988bf 100644 --- a/test/AlignmentSpec.hs +++ b/test/AlignmentSpec.hs @@ -190,6 +190,9 @@ data Child = Child toSource :: [Child] -> Source.Source Char toSource = Source.fromList . concatMap show +toSources :: [Join These Child] -> Both (Source.Source Char) +toSources = fmap toSource . toChildLists + toChildLists :: [Join These Child] -> Both [Child] toChildLists = foldMap (modifyJoin (fromThese [] []) . fmap (:[]))