Tooling-friendly ModSummary

Alan & Kim Zimmerman alan.zimm at
Mon Sep 5 18:27:26 UTC 2016

At the moment the standard way to use the GHC API is something like

                        _ <- load LoadAllTargets
                        modSum <- getModSummary mn
                        p <- parseModule modSum

And likewise if renamed or typechecked ASTs are needed.

But the `load` step already does all those phases.

So, would there be any objection to modifying the ModSummary to possibly
retain those artifacts, configurable via a DynFlag?

I would expect the flag would default to retaining none, but could then
either provide for returning all artifacts, or just for the targets
explicitly listed in the `setTargets` call (i.e. not the full `depanal`

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the ghc-devs mailing list