on develop help sign in
Merge branch 'no-fromJust' into patch-map-inner-patch-desugar
commitacd5b6abee01229896612dc5ac533bea0a275de3 authorJohn Ericson <John.Ericson@Obsidian.Systems> dateWed 5 Feb 2020, 17:49 (7 years ago) parent4fb60c49f0f5f9
1 file changed+3−1
src/Data/Patch/MapWithPatchingMove.hs+3−1
src/Data/Patch/MapWithPatchingMove.hs+3−1
@@ -268,7 +268,9 @@ patchThatChangesMap oldByIndex newByIndex = patch
268268 putRemainingKeys $ Set.delete k fromKs
269269 return $ NodeInfo (From_Move k mempty) $ Just undefined -- There's an existing value, and it's here, so no patch necessary
270270 else do
271− (fromK, remainingKeys) <- return . fromMaybe (error "patchThatChangesMap: impossible: fromKs was empty") $ Set.minView fromKs -- There's an existing value, but it's not here; move it here
271+ (fromK, remainingKeys) <- return $
272+ fromMaybe (error "PatchMapWithPatchingMove.patchThatChangesMap: impossible: fromKs was empty") $
273+ Set.minView fromKs -- There's an existing value, but it's not here; move it here
272274 putRemainingKeys remainingKeys
273275 return $ NodeInfo (From_Move fromK mempty) $ Just undefined
274276 Map.traverseWithKey f newByIndex