git.iko.soy/rowtype-yoga/purescript-native
on golang help sign in
Minor clean up of pattern match exception message
commite7cb2a9ba9c096370631d303ad12473cd9768767 authorAndy Arvanitis <andyarvanitis@gmail.com> dateThu 11 Jul 2019, 21:36 (7 years ago) parente81ea12
2 files changed+1−3
src/CodeGen/IL.hs+1−1 src/CodeGen/IL/Printer.hs−2
src/CodeGen/IL.hs+1−1
@@ -269,7 +269,7 @@ moduleToIL (Module _ coms mn _ imps _ foreigns decls) _ =
269269 go _ _ _ = internalError "Invalid arguments to bindersToIL"
270270
271271 failedPatternMessage :: Text
272− failedPatternMessage = "Failed pattern match at " <> runModuleName mn <> " " <> displayStartEndPos ss <> ": "
272+ failedPatternMessage = "Failed pattern match at " <> runModuleName mn <> " " <> displayStartEndPos ss
273273
274274 guardsToIL :: Either [(Guard Ann, Expr Ann)] (Expr Ann) -> m [AST]
275275 guardsToIL (Left gs) = traverse genGuard gs where
src/CodeGen/IL/Printer.hs−2
@@ -278,8 +278,6 @@ literals = mkPattern' match'
278278 -- match (Throw _ _) = return mempty
279279 match (Throw _ value) = mconcat <$> sequence
280280 [ return $ emit "panic("
281− , return $ emit "\"PatternMatchFailure: \""
282− , return $ emit " + "
283281 , prettyPrintIL' value
284282 , return $ emit ")"
285283 ]