From 43cd96e6ccd347010ec1c83919253921f9336a78 Mon Sep 17 00:00:00 2001 From: techieAgnostic <s@p7.co.nz> Date: Sat, 18 May 2019 19:46:00 +1200 Subject: [PATCH] fixed non exhaustive on rmFirstMatch --- State.hs | 1 + 1 file changed, 1 insertion(+) diff --git a/State.hs b/State.hs index 336bd47..5fca0be 100644 --- a/State.hs +++ b/State.hs @@ -39,6 +39,7 @@ numPut :: Either MainCharacter MainEva -> PutCards -> Integer numPut c p = toInteger $ length $ filter (\x -> (fst x) == c) p rmFirstMatch :: [a] -> (a -> Bool) -> [a] +rmFirstMatch [] _ = [] rmFirstMatch (l:ls) f | f l = ls | otherwise = (l : rmFirstMatch ls f)