How to set a program's command line arguments for GHCi?

后端 未结 3 604
忘了有多久
忘了有多久 2021-01-31 15:10

Suppose some Haskell file is executed with

runghc Queens.hs gecode_compile

Now, this fails, and I want to debug it with ghci. How

3条回答
  •  挽巷
    挽巷 (楼主)
    2021-01-31 15:38

    You can also set the command line arguments in ghci

    ghci> :set args foo bar
    ghci> main
    

    or

    ghci> :main foo bar
    

提交回复
热议问题