ghc-mod/Language/Haskell/GhcMod/Doc.hs
Daniil Frumin 9eb446e24b Moving all CPP stuff (that depends on GHC version) to Gap
- Moved some functions from Language.Haskell.GhcMod.Doc to Gap
- Moved HasType typeclass and some functions from Info to Gap
- Adjusted all the other modules to use necessary functions from Gap
  instead of the functions from modified modules
2013-07-02 12:48:44 +04:00

19 lines
658 B
Haskell

module Language.Haskell.GhcMod.Doc where
import DynFlags (DynFlags)
import Language.Haskell.GhcMod.Gap (withStyle, styleUnqualified)
import Outputable
import Pretty
styleQualified :: PprStyle
styleQualified = mkUserStyle alwaysQualify AllTheWay
showQualifiedPage :: DynFlags -> SDoc -> String
showQualifiedPage dflag = showDocWith PageMode . withStyle dflag styleQualified
showQualifiedOneLine :: DynFlags -> SDoc -> String
showQualifiedOneLine dflag = showDocWith OneLineMode . withStyle dflag styleQualified
showUnqualifiedOneLine :: DynFlags -> SDoc -> String
showUnqualifiedOneLine dflag = showDocWith OneLineMode . withStyle dflag styleUnqualified