git.iko.soy/rowtype-yoga/purescript-native
on golang help sign in
Merge pull request #82 from joprice/errorMessage

improve error message on corefn parse failure

commit355eb9b0f9d1a19372a1293b97b848d56310bab8 authorAndy Arvanitis <andyarvanitis@gmail.com> dateMon 27 Mar 2023, 21:01 (4 years ago) parente765507af7eeb4
1 file changed+2−2
unifiedsplit
app/Main.hs+2−2
app/Main.hs+2−2
@@ -44,7 +44,7 @@ import CodeGen.IL.Printer
4444import Tests
4545
4646data Command = Build | Run (Maybe String)
47−
47+
4848parseJson :: Text -> Value
4949parseJson text
5050 | Just fileJson <- decode . L.encodeUtf8 $ L.fromStrict text = fileJson
@@ -54,7 +54,7 @@ jsonToModule :: Value -> Module Ann
5454jsonToModule value =
5555 case parse moduleFromJSON value of
5656 Success (_, r) -> r
57− _ -> error "failed"
57+ _ -> error "Failed parsing corefn. Psgo currently supports purescript <= 0.13.8"
5858
5959splitArgs :: [String] -> ([String], Maybe String, [String])
6060splitArgs args =