Skip to content

Ensure tcg_env is up-to-date when running typechecker plugins

alexbiehl-gc requested to merge alexbiehl-gc/ghc:alex/tcg_env into master

While making Haddock's interface creation a typechecker plugin I noticed that GHC doesn't have the most up-to-date tcg_env in the TcM environment when running plugins. This MR fixes that.

Currently as a workaround I am using setGblEnv in the plugin but it would be nice if GHC did the right thing in the first place.


Thank you for your contribution to GHC!

Please take a few moments to verify that your commits fulfill the following:

  • are either individually buildable or squashed
  • have commit messages which describe what they do (referring to Notes and tickets using #NNNN syntax when appropriate)
  • have added source comments describing your change. For larger changes you likely should add a Note and cross-reference it from the relevant places.
  • add a testcase to the testsuite.
  • replace this message with a description motivating your change

If you have any questions don't hesitate to open your merge request and inquire in a comment. If your patch isn't quite done yet please do add prefix your MR title with WIP:.

Edited by alexbiehl-gc

Merge request reports