From bac2f24871d95eeb3aa3fc898a7656fc4f5f094a Mon Sep 17 00:00:00 2001 From: Yann Herklotz Date: Mon, 1 Apr 2019 10:55:40 +0100 Subject: Run through brittany --- app/Main.hs | 51 +++++++++++++++++++++++++++------------------------ 1 file changed, 27 insertions(+), 24 deletions(-) (limited to 'app') diff --git a/app/Main.hs b/app/Main.hs index f9ecb52..c214929 100644 --- a/app/Main.hs +++ b/app/Main.hs @@ -66,30 +66,33 @@ fuzzOpts = Fuzz <$> textOption rerunOpts :: Parser Opts rerunOpts = Rerun - <$> some (option - (optReader parseSynth) - ( long "synth" - <> metavar "SYNTH" - <> help "Rerun using a synthesiser (yosys|xst)." - <> showDefault - <> value Yosys - ) - <|> option - (optReader parseSim) - ( long "sim" - <> metavar "SIM" - <> help "Rerun using a simulator (icarus)." - <> showDefault - <> value Icarus - ) - ) + <$> some + ( option + (optReader parseSynth) + ( long "synth" + <> metavar "SYNTH" + <> help "Rerun using a synthesiser (yosys|xst)." + <> showDefault + <> value Yosys + ) + <|> option + (optReader parseSim) + ( long "sim" + <> metavar "SIM" + <> help "Rerun using a simulator (icarus)." + <> showDefault + <> value Icarus + ) + ) <*> (S.fromText <$> textOption - ( long "input" - <> short 'i' - <> metavar "FILE" - <> help "Verilog file input." - <> showDefault - <> value "rtl.v")) + ( long "input" + <> short 'i' + <> metavar "FILE" + <> help "Verilog file input." + <> showDefault + <> value "rtl.v" + ) + ) genOpts :: Parser Opts genOpts = Generate . S.fromText <$> textOption @@ -205,7 +208,7 @@ handleOpts (Parse f) = do Left l -> print l Right v -> print $ V.GenVerilog v where file = T.unpack . S.toTextIgnore $ f -handleOpts (Rerun _ _) = undefined +handleOpts (Rerun _ _) = undefined handleOpts (Reduce f t) = do verilogSrc <- readFile file case V.parseVerilog file verilogSrc of -- cgit