The Wiki is a comprehensive resource about GHC development. Use it when this cheatsheet is insufficient.
Documentation for master is built with GitLab CI:
User's Guide – command line options, language extensions, and so on.
Libraries – Haddock for base, containers, transformers, and other boot libraries.
GHC has its own GitLab instance. You can sign in with your GitHub account.
git clone --recurse-submodules https://gitlab.haskell.org/ghc/ghc.git git pull also requires --recurse-submodules because GHC uses git submodules.
Nix users are fortunate to have ghc.nix:
git clone https://github.com/alpmestan/ghc.nix nix-shell ghc.nix This will install alex, happy, texlive, and other build dependencies.
For the first time:
./boot && ./configure cabal v2-update hadrian/build -j --flavour=Quick Quick stage2 rebuild:
hadrian/build -j --flavour=Quick --freeze1 The build artifacts are stored in the _build directory.
Run the freshly built GHCi:
_build/stage1/bin/ghc --interactive Run a particular set of tests:
hadrian/build -j --flavour=Quick --freeze1 test --only="T1 T2 T3" Use -a to accept the output of failing tests.
Omit --only to run the entire testsuite.
Pass the -ddump-tc-trace flag to dump the type checker debug output; -ddump-rn-trace for the renamer.
Build GHC with assertions enabled:
hadrian/build -j --flavour=Devel2 To build the User's Guide and Haddock documentation for boot libraries:
hadrian/build -j --flavour=Quick --freeze1 docs --docs=no-sphinx-pdfs The generated HTML documentation is saved at:
_build/docs/html/index.htmlTo report a bug, use the GitLab issue tracker.
To contribute a change, open a GitLab merge request.
To propose a new language feature, the ghc-proposals platform.
For a technical discussion or a question, the ghc-devs mailing list or the #ghc channel on Freenode (IRC).