1
1
mirror of https://github.com/github/semantic.git synced 2024-11-28 10:15:55 +03:00

Recur through SES via constructAndRun.

This commit is contained in:
Rob Rix 2015-11-18 10:39:20 -08:00
parent 9fd3be3408
commit c2deb95a36

View File

@ -36,7 +36,7 @@ run (Free (ByKey a b f)) = run $ f byKey where
inserted = (Pure . Insert) <$> difference b a
patched = intersectionWith interpret a b
run (Free (ByIndex a b f)) = run $ f $ ses a b
run (Free (ByIndex a b f)) = run $ f $ ses constructAndRun a b
interpret :: Term a Info -> Term a Info -> Diff a
interpret a b = maybeReplace $ constructAndRun a b where