A plugin for modifying the candidate hole fits *before* they're checked.
Moduleghc-9.10.3GHC2021
GHC.Tc.Errors.Hole.Plugin
- 4 types
- Packageghc-9.10.3
- Exports4
- LanguageGHC2021
- LicenceBSD-3-Clause
- SourcePlugin.hs
A plugin for modifying hole fits *after* they've been found.
A HoleFitPlugin is a pair of candidate and fit plugins.
Constructors
HoleFitPluginR adds a TcRef to hole fit plugins so that plugins can track internal state. Note the existential quantification, ensuring that the state cannot be modified from outside the plugin.
Constructors
forall s. HoleFitPluginRhfPluginInit :: TcM (TcRef s)Initializes the TcRef to be passed to the plugin
hfPluginRun :: TcRef s -> HoleFitPluginThe function defining the plugin itself
hfPluginStop :: TcRef s -> TcM ()Cleanup of state, guaranteed to be called even on error