git.iko.soy/rowtype-yoga/purescript-native
on golang help sign in
Merge pull request #854 from michaelficarra/GH-851

fixes #851: terminate parser errors with a newline

commit335345abcdeff0045aa748d62b6bb072cc0ef88e authorPhil Freeman <paf31@cantab.net> dateSun 8 Feb 2015, 19:09 (12 years ago) parent00086aa3687faa
2 files changed+4−4
psc-docs/Main.hs+2−2 psc/Main.hs+2−2
psc-docs/Main.hs+2−2
@@ -28,7 +28,7 @@ import Options.Applicative
2828import qualified Language.PureScript as P
2929import qualified Paths_purescript as Paths
3030import System.Exit (exitSuccess, exitFailure)
31−import System.IO (hPutStr, stderr)
31+import System.IO (hPutStrLn, stderr)
3232
3333
3434data PSCDocsOptions = PSCDocsOptions
@@ -42,7 +42,7 @@ docgen (PSCDocsOptions showHierarchy input) = do
4242 e <- P.parseModulesFromFiles (fromMaybe "") <$> mapM (fmap (first Just) . parseFile) (nub input)
4343 case e of
4444 Left err -> do
45− hPutStr stderr $ show err
45+ hPutStrLn stderr $ show err
4646 exitFailure
4747 Right ms -> do
4848 putStrLn . runDocs $ (renderModules showHierarchy) (map snd ms)
psc/Main.hs+2−2
@@ -26,7 +26,7 @@ import Options.Applicative as Opts
2626import System.Directory (createDirectoryIfMissing)
2727import System.FilePath (takeDirectory)
2828import System.Exit (exitSuccess, exitFailure)
29−import System.IO (hPutStr, hPutStrLn, stderr)
29+import System.IO (hPutStrLn, stderr)
3030
3131import qualified Language.PureScript as P
3232import qualified Paths_purescript as Paths
@@ -58,7 +58,7 @@ compile (PSCOptions input opts stdin output externs usePrefix) = do
5858 modules <- P.parseModulesFromFiles (fromMaybe "") <$> readInput (InputOptions (P.optionsNoPrelude opts) stdin input)
5959 case modules of
6060 Left err -> do
61− hPutStr stderr $ show err
61+ hPutStrLn stderr $ show err
6262 exitFailure
6363 Right ms -> do
6464 case P.compile opts (map snd ms) prefix of