hsdev-0.1.2.1: Haskell development library and tool with support of autocompletion, symbol info, go to declaration, find references etc.

Safe HaskellNone
LanguageHaskell98

HsDev.Tools.GhcMod.InferType

Synopsis

Documentation

untyped :: DeclarationInfo -> Bool Source

Is declaration untyped

inferType :: [String] -> Cabal -> FilePath -> Maybe Project -> String -> Declaration -> GhcModT IO Declaration Source

Infer type of declaration

inferTypes :: [String] -> Cabal -> Module -> GhcModT IO Module Source

Infer types for module

data GhcModT m a :: (* -> *) -> * -> *

This is basically a newtype wrapper around StateT, ErrorT, JournalT and ReaderT with custom instances for GhcMonad and it's constraints that means you can run (almost) all functions from the GHC API on top of GhcModT transparently.

The inner monad m should have instances for MonadIO and MonadBaseControl IO, in the common case this is simply IO. Most mtl monads already have MonadBaseControl IO instances, see the monad-control package.