我可以从GHCi中找到GHC版本吗?
?>
我在GHCi里面输入什么来发现它使用的是哪个 GHC 版本?
回答
> import System.Info
> :browse
arch :: String
compilerName :: String
compilerVersion :: Data.Version.Version
os :: String
> compilerVersion
Version {versionBranch = [8,10], versionTags = []}
> compilerName
"ghc"
最重要的是,GHCi 在启动时打印其版本:
GHCi, version 8.10.3: https://www.haskell.org/ghc/ :? for help