How to upgrade stack ghc

2019-04-06 14:07发布

问题:

stack ghc -- --version

The Glorious Glasgow Haskell Compilation System, version 7.10.3

I want to upgrade to ghc 8.

How can I tell stack to upgrade ghc?

回答1:

dysfun from the IRC answered my question so I will post it here for more posterity.

To update the ghc used to compile a project, go to the yaml file. In there is the resolver field. Update that accordingly.

For my case, I found this webpage https://www.stackage.org/lts-9.0