8
lib/AoC.hs
Normal file
8
lib/AoC.hs
Normal file
@@ -0,0 +1,8 @@
|
||||
module AoC where
|
||||
|
||||
import Text.Parsec (ParseError)
|
||||
|
||||
-- extract Right value after parsing
|
||||
extract :: Either ParseError a -> a
|
||||
extract (Left err) = error ("Parsing failed: " ++ show err)
|
||||
extract (Right val) = val
|
||||
Reference in New Issue
Block a user