ref: 4b09e427931ca2909c4f27b3d4fadc3e6ec25a04
parent: 9006d5665d603cd81f074e762d5b653e412aed5f
author: Lennart Augustsson <lennart@augustsson.net>
date: Sat Oct 28 16:55:40 EDT 2023
Avoid a _noMatch
--- a/lib/Data/List.hs
+++ b/lib/Data/List.hs
@@ -158,9 +158,9 @@
isPrefixOf = isPrefixOfBy (==)
isPrefixOfBy :: forall a . (a -> a -> Bool) -> [a] -> [a] -> Bool
-isPrefixOfBy _ [] _ = True
-isPrefixOfBy _ _ [] = False
isPrefixOfBy eq (c:cs) (d:ds) = eq c d && isPrefixOfBy eq cs ds
+isPrefixOfBy _ [] _ = True
+isPrefixOfBy _ _ _ = False
splitAt :: forall a . P.Int -> [a] -> ([a], [a])
splitAt n xs = (take n xs, drop n xs)
--
⑨