mirror of
https://github.com/github/semantic.git
synced 2024-12-01 09:15:01 +03:00
Add delete & insert bindings.
This commit is contained in:
parent
37f6c02432
commit
bf333bc073
@ -36,6 +36,8 @@ diffAt diffTerms cost (i, j) (a : as) (b : bs) = do
|
||||
put $ Map.insert (i, j) [] cachedDiffs
|
||||
return []
|
||||
where
|
||||
delete = (id &&& cost) (Pure . Delete $ a)
|
||||
insert = (id &&& cost) (Pure . Insert $ b)
|
||||
sumCost script = sum $ snd <$> script
|
||||
best options = minimumBy (comparing sumCost) options
|
||||
recur = diffAt diffTerms cost
|
||||
|
Loading…
Reference in New Issue
Block a user