module HsImport.Config
( Config(..)
, defaultConfig
) where
import qualified Language.Haskell.Exts as HS
import qualified HsImport.PrettyPrint as PP
import qualified HsImport.ImportPos as IP
type HsImportDecl = HS.ImportDecl HS.SrcSpanInfo
data Config = Config
{
prettyPrint :: HsImportDecl -> String
, findImportPos :: HsImportDecl -> [HsImportDecl] -> Maybe IP.ImportPos
, configError :: Maybe String
}
defaultConfig :: Config
defaultConfig = Config
{ prettyPrint = PP.prettyPrint
, findImportPos = IP.findImportPos
, configError = Nothing
}