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` result).

Regards
  Alan