haskell-language-server-2.9.0.0: LSP server for GHC

Safe Haskell | None
Language | GHC2021

Development.IDE.GHC.ExactPrint

Contents

- Helper function
- Orphan instances

Description

This module hosts various abstractions and utility functions to work with ghc-exactprint.

Synopsis

- newtype Graft (m :: Type -> Type) a = Graft {
  - runGraft :: DynFlags -> a -> TransformT m a
  }
- graftDecls :: HasDecls a => SrcSpan -> [LHsDecl GhcPs] -> Graft (Either String) a
- graftDeclsWithM :: forall a (m :: Type -> Type). (HasDecls a, MonadFail m) => SrcSpan -> (LHsDecl GhcPs -> TransformT m (Maybe [LHsDecl GhcPs])) -> Graft m a
- annotate :: ASTElement l ast => DynFlags -> Bool -> LocatedAn l ast -> TransformT (Either String) (LocatedAn l ast)
- annotateDecl :: DynFlags -> LHsDecl GhcPs -> TransformT (Either String) (LHsDecl GhcPs)
- hoistGraft :: (forall x. m x -> n x) -> Graft m a -> Graft n a
- graftWithM :: forall ast (m :: Type -> Type) a l. (MonadFail m, Data a, ASTElement l ast) => SrcSpan -> (LocatedAn l ast -> TransformT m (Maybe (LocatedAn l ast))) -> Graft m a
- graftExprWithM :: forall (m :: Type -> Type) a. (MonadFail m, Data a) => SrcSpan -> (LHsExpr GhcPs -> TransformT m (Maybe (LHsExpr GhcPs))) -> Graft m a
- genericGraftWithSmallestM :: forall (m :: Type -> Type) a ast. (Monad m, Data a, Typeable ast) => Proxy (Located ast) -> SrcSpan -> (DynFlags -> ast -> GenericM (TransformT m)) -> Graft m a
- genericGraftWithLargestM :: forall (m :: Type -> Type) a ast. (Monad m, Data a, Typeable ast) => Proxy (Located ast) -> SrcSpan -> (DynFlags -> ast -> GenericM (TransformT m)) -> Graft m a
- graftSmallestDeclsWithM :: HasDecls a => SrcSpan -> (LHsDecl GhcPs -> TransformT (Either String) (Maybe [LHsDecl GhcPs])) -> Graft (Either String) a
- transform :: DynFlags -> ClientCapabilities -> VersionedTextDocumentIdentifier -> Graft (Either String) ParsedSource -> ParsedSource -> Either String WorkspaceEdit
- transformM :: Monad m => DynFlags -> ClientCapabilities -> VersionedTextDocumentIdentifier -> Graft (ExceptStringT m) ParsedSource -> ParsedSource -> m (Either String WorkspaceEdit)
- class Typeable a => ExactPrint a where
  - getAnnotationEntry :: a -> Entry
  - setAnnotationAnchor :: a -> Anchor -> [TrailingAnn] -> EpAnnComments -> a
  - exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => a -> EP w m a
- modifySmallestDeclWithM :: (HasDecls a, Monad m) => (SrcSpan -> m Bool) -> (LHsDecl GhcPs -> TransformT m ([LHsDecl GhcPs], r)) -> a -> TransformT m (a, Maybe r)
- modifyMgMatchesT :: forall (m :: Type -> Type). Monad m => MatchGroup GhcPs (LHsExpr GhcPs) -> (LMatch GhcPs (LHsExpr GhcPs) -> TransformT m (LMatch GhcPs (LHsExpr GhcPs))) -> TransformT m (MatchGroup GhcPs (LHsExpr GhcPs))
- modifyMgMatchesT' :: Monad m => MatchGroup GhcPs (LHsExpr GhcPs) -> (LMatch GhcPs (LHsExpr GhcPs) -> TransformT m (LMatch GhcPs (LHsExpr GhcPs), r)) -> r -> (r -> r -> m r) -> TransformT m (MatchGroup GhcPs (LHsExpr GhcPs), r)
- modifySigWithM :: forall a (m :: Type -> Type). (HasDecls a, Monad m, ExactPrint a) => IdP GhcPs -> (LHsSigType GhcPs -> LHsSigType GhcPs) -> a -> TransformT m a
- genAnchor1 :: Anchor
- setPrecedingLines :: LocatedAn t a -> Int -> Int -> LocatedAn t a
- addParens :: Bool -> NameAnn -> NameAnn
- addParensToCtxt :: Maybe EpaLocation -> AnnContext -> AnnContext
- modifyAnns :: LocatedAn a ast -> (a -> a) -> LocatedAn a ast
- removeComma :: SrcSpanAnnA -> SrcSpanAnnA
- eqSrcSpan :: SrcSpan -> SrcSpan -> Bool
- epl :: Int -> EpaLocation
- epAnn :: SrcSpan -> ann -> EpAnn ann
- removeTrailingComma :: GenLocated SrcSpanAnnA ast -> GenLocated SrcSpanAnnA ast
- annotateParsedSource :: ParsedModule -> ParsedSource
- getAnnotatedParsedSourceRule :: Recorder (WithPriority Log) -> Rules ()
- data GetAnnotatedParsedSource = GetAnnotatedParsedSource
- class (Data ast, Typeable l, Outputable l, Outputable ast) => ASTElement l ast | ast -> l where
  - parseAST :: Parser (LocatedAn l ast)
  - maybeParensAST :: LocatedAn l ast -> LocatedAn l ast
  - graft :: Data a => SrcSpan -> LocatedAn l ast -> Graft (Either String) a
- newtype ExceptStringT (m :: Type -> Type) a = ExceptStringT {
  - runExceptString :: ExceptT String m a
  }
- data TransformT (m :: Type -> Type) a
- data Log = LogShake Log

# Documentation

newtype Graft (m :: Type -> Type) a #

A transformation for grafting source trees together. Use the semigroup instance to combine `Graft`s, and run them via `transform`.

Constructors

Graft |

Fields

- runGraft :: DynFlags -> a -> TransformT m a

#### Instances

Instances details

Monad m => Monoid (Graft m a) # |
Instance details Defined in Development.IDE.GHC.ExactPrint Methods mempty :: Graft m a # mappend :: Graft m a -> Graft m a -> Graft m a # mconcat :: [Graft m a] -> Graft m a #
Monad m => Semigroup (Graft m a) # |
Instance details Defined in Development.IDE.GHC.ExactPrint Methods (<>) :: Graft m a -> Graft m a -> Graft m a # sconcat :: NonEmpty (Graft m a) -> Graft m a # stimes :: Integral b => b -> Graft m a -> Graft m a #

graftDecls :: HasDecls a => SrcSpan -> [LHsDecl GhcPs] -> Graft (Either String) a #

graftDeclsWithM :: forall a (m :: Type -> Type). (HasDecls a, MonadFail m) => SrcSpan -> (LHsDecl GhcPs -> TransformT m (Maybe [LHsDecl GhcPs])) -> Graft m a #

annotate :: ASTElement l ast => DynFlags -> Bool -> LocatedAn l ast -> TransformT (Either String) (LocatedAn l ast) #

Given an `LHSExpr`, compute its exactprint annotations. Note that this function will throw away any existing annotations (and format)

annotateDecl :: DynFlags -> LHsDecl GhcPs -> TransformT (Either String) (LHsDecl GhcPs) #

Given an `LHsDecl`, compute its exactprint annotations.

hoistGraft :: (forall x. m x -> n x) -> Graft m a -> Graft n a #

graftWithM :: forall ast (m :: Type -> Type) a l. (MonadFail m, Data a, ASTElement l ast) => SrcSpan -> (LocatedAn l ast -> TransformT m (Maybe (LocatedAn l ast))) -> Graft m a #

graftExprWithM :: forall (m :: Type -> Type) a. (MonadFail m, Data a) => SrcSpan -> (LHsExpr GhcPs -> TransformT m (Maybe (LHsExpr GhcPs))) -> Graft m a #

genericGraftWithSmallestM #

Arguments

:: forall (m :: Type -> Type) a ast. (Monad m, Data a, Typeable ast) |
=> Proxy (Located ast) | The type of nodes we'd like to consider when finding the smallest.
-> SrcSpan |
-> (DynFlags -> ast -> GenericM (TransformT m)) |
-> Graft m a |

Run the given transformation only on the smallest node in the tree that contains the `SrcSpan`.

genericGraftWithLargestM #

Arguments

:: forall (m :: Type -> Type) a ast. (Monad m, Data a, Typeable ast) |
=> Proxy (Located ast) | The type of nodes we'd like to consider when finding the largest.
-> SrcSpan |
-> (DynFlags -> ast -> GenericM (TransformT m)) |
-> Graft m a |

Run the given transformation only on the largest node in the tree that contains the `SrcSpan`.

graftSmallestDeclsWithM :: HasDecls a => SrcSpan -> (LHsDecl GhcPs -> TransformT (Either String) (Maybe [LHsDecl GhcPs])) -> Graft (Either String) a #

transform :: DynFlags -> ClientCapabilities -> VersionedTextDocumentIdentifier -> Graft (Either String) ParsedSource -> ParsedSource -> Either String WorkspaceEdit #

Convert a `Graft` into a `WorkspaceEdit`.

transformM :: Monad m => DynFlags -> ClientCapabilities -> VersionedTextDocumentIdentifier -> Graft (ExceptStringT m) ParsedSource -> ParsedSource -> m (Either String WorkspaceEdit) #

Convert a `Graft` into a `WorkspaceEdit`.

class Typeable a => ExactPrint a where #

An AST fragment with an annotation must be able to return the requirements for nesting another one, captured in an `Entry`, and to be able to use the rest of the exactprint machinery to print the element. In the analogy to Outputable, `exact` plays the role of `ppr`.

Methods

getAnnotationEntry :: a -> Entry #

setAnnotationAnchor :: a -> Anchor -> [TrailingAnn] -> EpAnnComments -> a #

exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => a -> EP w m a #

#### Instances

Instances details

ExactPrint FastString |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: FastString -> Entry # setAnnotationAnchor :: FastString -> Anchor -> [TrailingAnn] -> EpAnnComments -> FastString # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => FastString -> EP w m FastString #
ExactPrint NamespaceSpecifier |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: NamespaceSpecifier -> Entry # setAnnotationAnchor :: NamespaceSpecifier -> Anchor -> [TrailingAnn] -> EpAnnComments -> NamespaceSpecifier # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => NamespaceSpecifier -> EP w m NamespaceSpecifier #
ExactPrint HsDocString |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: HsDocString -> Entry # setAnnotationAnchor :: HsDocString -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsDocString # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsDocString -> EP w m HsDocString #
ExactPrint HsDocStringChunk |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: HsDocStringChunk -> Entry # setAnnotationAnchor :: HsDocStringChunk -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsDocStringChunk # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsDocStringChunk -> EP w m HsDocStringChunk #
ExactPrint CCallConv |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: CCallConv -> Entry # setAnnotationAnchor :: CCallConv -> Anchor -> [TrailingAnn] -> EpAnnComments -> CCallConv # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => CCallConv -> EP w m CCallConv #
ExactPrint CExportSpec |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: CExportSpec -> Entry # setAnnotationAnchor :: CExportSpec -> Anchor -> [TrailingAnn] -> EpAnnComments -> CExportSpec # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => CExportSpec -> EP w m CExportSpec #
ExactPrint Safety |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: Safety -> Entry # setAnnotationAnchor :: Safety -> Anchor -> [TrailingAnn] -> EpAnnComments -> Safety # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => Safety -> EP w m Safety #
ExactPrint StringLiteral |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: StringLiteral -> Entry # setAnnotationAnchor :: StringLiteral -> Anchor -> [TrailingAnn] -> EpAnnComments -> StringLiteral # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => StringLiteral -> EP w m StringLiteral #
ExactPrint InWarningCategory |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: InWarningCategory -> Entry # setAnnotationAnchor :: InWarningCategory -> Anchor -> [TrailingAnn] -> EpAnnComments -> InWarningCategory # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => InWarningCategory -> EP w m InWarningCategory #
ExactPrint Role |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: Role -> Entry # setAnnotationAnchor :: Role -> Anchor -> [TrailingAnn] -> EpAnnComments -> Role # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => Role -> EP w m Role #
ExactPrint ModuleName |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: ModuleName -> Entry # setAnnotationAnchor :: ModuleName -> Anchor -> [TrailingAnn] -> EpAnnComments -> ModuleName # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => ModuleName -> EP w m ModuleName #
ExactPrint HsIPName |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: HsIPName -> Entry # setAnnotationAnchor :: HsIPName -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsIPName # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsIPName -> EP w m HsIPName #
ExactPrint DataFamInstDeclWithContext |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: DataFamInstDeclWithContext -> Entry # setAnnotationAnchor :: DataFamInstDeclWithContext -> Anchor -> [TrailingAnn] -> EpAnnComments -> DataFamInstDeclWithContext # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => DataFamInstDeclWithContext -> EP w m DataFamInstDeclWithContext #
ExactPrint HsModuleImpDecls |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: HsModuleImpDecls -> Entry # setAnnotationAnchor :: HsModuleImpDecls -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsModuleImpDecls # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsModuleImpDecls -> EP w m HsModuleImpDecls #
ExactPrint Void |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: Void -> Entry # setAnnotationAnchor :: Void -> Anchor -> [TrailingAnn] -> EpAnnComments -> Void # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => Void -> EP w m Void #
ExactPrint (BooleanFormula (LocatedN RdrName)) |

Instance details

Defined in Language.Haskell.GHC.ExactPrint.ExactPrint

Methods

getAnnotationEntry :: BooleanFormula (LocatedN RdrName) -> Entry #

setAnnotationAnchor :: BooleanFormula (LocatedN RdrName) -> Anchor -> [TrailingAnn] -> EpAnnComments -> BooleanFormula (LocatedN RdrName) #

exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => BooleanFormula (LocatedN RdrName) -> EP w m (BooleanFormula (LocatedN RdrName)) #

ExactPrint a => ExactPrint (LocatedA a) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: LocatedA a -> Entry # setAnnotationAnchor :: LocatedA a -> Anchor -> [TrailingAnn] -> EpAnnComments -> LocatedA a # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => LocatedA a -> EP w m (LocatedA a) #
ExactPrint a => ExactPrint (LocatedC a) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: LocatedC a -> Entry # setAnnotationAnchor :: LocatedC a -> Anchor -> [TrailingAnn] -> EpAnnComments -> LocatedC a # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => LocatedC a -> EP w m (LocatedC a) #
ExactPrint a => ExactPrint (LocatedE a) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: LocatedE a -> Entry # setAnnotationAnchor :: LocatedE a -> Anchor -> [TrailingAnn] -> EpAnnComments -> LocatedE a # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => LocatedE a -> EP w m (LocatedE a) #
ExactPrint (LocatedL (BooleanFormula (LocatedN RdrName))) |

Instance details

Defined in Language.Haskell.GHC.ExactPrint.ExactPrint

Methods

getAnnotationEntry :: LocatedL (BooleanFormula (LocatedN RdrName)) -> Entry #

setAnnotationAnchor :: LocatedL (BooleanFormula (LocatedN RdrName)) -> Anchor -> [TrailingAnn] -> EpAnnComments -> LocatedL (BooleanFormula (LocatedN RdrName)) #

exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => LocatedL (BooleanFormula (LocatedN RdrName)) -> EP w m (LocatedL (BooleanFormula (LocatedN RdrName))) #

ExactPrint (Match GhcPs (LocatedA body)) => ExactPrint (LocatedL [LocatedA (Match GhcPs (LocatedA body))]) |

Instance details

Defined in Language.Haskell.GHC.ExactPrint.ExactPrint

Methods

getAnnotationEntry :: LocatedL [LocatedA (Match GhcPs (LocatedA body))] -> Entry #

setAnnotationAnchor :: LocatedL [LocatedA (Match GhcPs (LocatedA body))] -> Anchor -> [TrailingAnn] -> EpAnnComments -> LocatedL [LocatedA (Match GhcPs (LocatedA body))] #

exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => LocatedL [LocatedA (Match GhcPs (LocatedA body))] -> EP w m (LocatedL [LocatedA (Match GhcPs (LocatedA body))]) #

ExactPrint (LocatedL [LocatedA (StmtLR GhcPs GhcPs (LocatedA (HsCmd GhcPs)))]) |

Instance details

Defined in Language.Haskell.GHC.ExactPrint.ExactPrint

Methods

getAnnotationEntry :: LocatedL [LocatedA (StmtLR GhcPs GhcPs (LocatedA (HsCmd GhcPs)))] -> Entry #

setAnnotationAnchor :: LocatedL [LocatedA (StmtLR GhcPs GhcPs (LocatedA (HsCmd GhcPs)))] -> Anchor -> [TrailingAnn] -> EpAnnComments -> LocatedL [LocatedA (StmtLR GhcPs GhcPs (LocatedA (HsCmd GhcPs)))] #

exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => LocatedL [LocatedA (StmtLR GhcPs GhcPs (LocatedA (HsCmd GhcPs)))] -> EP w m (LocatedL [LocatedA (StmtLR GhcPs GhcPs (LocatedA (HsCmd GhcPs)))]) #

ExactPrint (LocatedL [LocatedA (StmtLR GhcPs GhcPs (LocatedA (HsExpr GhcPs)))]) |

Instance details

Defined in Language.Haskell.GHC.ExactPrint.ExactPrint

Methods

getAnnotationEntry :: LocatedL [LocatedA (StmtLR GhcPs GhcPs (LocatedA (HsExpr GhcPs)))] -> Entry #

setAnnotationAnchor :: LocatedL [LocatedA (StmtLR GhcPs GhcPs (LocatedA (HsExpr GhcPs)))] -> Anchor -> [TrailingAnn] -> EpAnnComments -> LocatedL [LocatedA (StmtLR GhcPs GhcPs (LocatedA (HsExpr GhcPs)))] #

exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => LocatedL [LocatedA (StmtLR GhcPs GhcPs (LocatedA (HsExpr GhcPs)))] -> EP w m (LocatedL [LocatedA (StmtLR GhcPs GhcPs (LocatedA (HsExpr GhcPs)))]) #

ExactPrint (LocatedL [LocatedA (IE GhcPs)]) |

Instance details

Defined in Language.Haskell.GHC.ExactPrint.ExactPrint

Methods

getAnnotationEntry :: LocatedL [LocatedA (IE GhcPs)] -> Entry #

setAnnotationAnchor :: LocatedL [LocatedA (IE GhcPs)] -> Anchor -> [TrailingAnn] -> EpAnnComments -> LocatedL [LocatedA (IE GhcPs)] #

exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => LocatedL [LocatedA (IE GhcPs)] -> EP w m (LocatedL [LocatedA (IE GhcPs)]) #

ExactPrint (LocatedL [LocatedA (ConDeclField GhcPs)]) |

Instance details

Defined in Language.Haskell.GHC.ExactPrint.ExactPrint

Methods

getAnnotationEntry :: LocatedL [LocatedA (ConDeclField GhcPs)] -> Entry #

setAnnotationAnchor :: LocatedL [LocatedA (ConDeclField GhcPs)] -> Anchor -> [TrailingAnn] -> EpAnnComments -> LocatedL [LocatedA (ConDeclField GhcPs)] #

exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => LocatedL [LocatedA (ConDeclField GhcPs)] -> EP w m (LocatedL [LocatedA (ConDeclField GhcPs)]) #

ExactPrint (LocatedN RdrName) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: LocatedN RdrName -> Entry # setAnnotationAnchor :: LocatedN RdrName -> Anchor -> [TrailingAnn] -> EpAnnComments -> LocatedN RdrName # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => LocatedN RdrName -> EP w m (LocatedN RdrName) #
ExactPrint (LocatedP OverlapMode) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: LocatedP OverlapMode -> Entry # setAnnotationAnchor :: LocatedP OverlapMode -> Anchor -> [TrailingAnn] -> EpAnnComments -> LocatedP OverlapMode # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => LocatedP OverlapMode -> EP w m (LocatedP OverlapMode) #
ExactPrint (LocatedP CType) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: LocatedP CType -> Entry # setAnnotationAnchor :: LocatedP CType -> Anchor -> [TrailingAnn] -> EpAnnComments -> LocatedP CType # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => LocatedP CType -> EP w m (LocatedP CType) #
ExactPrint (LocatedP (WarningTxt GhcPs)) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: LocatedP (WarningTxt GhcPs) -> Entry # setAnnotationAnchor :: LocatedP (WarningTxt GhcPs) -> Anchor -> [TrailingAnn] -> EpAnnComments -> LocatedP (WarningTxt GhcPs) # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => LocatedP (WarningTxt GhcPs) -> EP w m (LocatedP (WarningTxt GhcPs)) #
ExactPrint a => ExactPrint (Located a) | Bare Located elements are simply stripped off without further processing.
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: Located a -> Entry # setAnnotationAnchor :: Located a -> Anchor -> [TrailingAnn] -> EpAnnComments -> Located a # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => Located a -> EP w m (Located a) #
ExactPrint (HsModule GhcPs) | 'Located (HsModule GhcPs)' corresponds to `ParsedSource`
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: HsModule GhcPs -> Entry # setAnnotationAnchor :: HsModule GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsModule GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsModule GhcPs -> EP w m (HsModule GhcPs) #
ExactPrint (HsBind GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: HsBind GhcPs -> Entry # setAnnotationAnchor :: HsBind GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsBind GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsBind GhcPs -> EP w m (HsBind GhcPs) #
ExactPrint (HsIPBinds GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: HsIPBinds GhcPs -> Entry # setAnnotationAnchor :: HsIPBinds GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsIPBinds GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsIPBinds GhcPs -> EP w m (HsIPBinds GhcPs) #
ExactPrint (HsLocalBinds GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: HsLocalBinds GhcPs -> Entry # setAnnotationAnchor :: HsLocalBinds GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsLocalBinds GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsLocalBinds GhcPs -> EP w m (HsLocalBinds GhcPs) #
ExactPrint (HsMultAnn GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: HsMultAnn GhcPs -> Entry # setAnnotationAnchor :: HsMultAnn GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsMultAnn GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsMultAnn GhcPs -> EP w m (HsMultAnn GhcPs) #
ExactPrint (IPBind GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: IPBind GhcPs -> Entry # setAnnotationAnchor :: IPBind GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> IPBind GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => IPBind GhcPs -> EP w m (IPBind GhcPs) #
ExactPrint (RecordPatSynField GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: RecordPatSynField GhcPs -> Entry # setAnnotationAnchor :: RecordPatSynField GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> RecordPatSynField GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => RecordPatSynField GhcPs -> EP w m (RecordPatSynField GhcPs) #
ExactPrint (Sig GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: Sig GhcPs -> Entry # setAnnotationAnchor :: Sig GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> Sig GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => Sig GhcPs -> EP w m (Sig GhcPs) #
ExactPrint (AnnDecl GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: AnnDecl GhcPs -> Entry # setAnnotationAnchor :: AnnDecl GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> AnnDecl GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => AnnDecl GhcPs -> EP w m (AnnDecl GhcPs) #
ExactPrint (ClsInstDecl GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: ClsInstDecl GhcPs -> Entry # setAnnotationAnchor :: ClsInstDecl GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> ClsInstDecl GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => ClsInstDecl GhcPs -> EP w m (ClsInstDecl GhcPs) #
ExactPrint (ConDecl GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: ConDecl GhcPs -> Entry # setAnnotationAnchor :: ConDecl GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> ConDecl GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => ConDecl GhcPs -> EP w m (ConDecl GhcPs) #
ExactPrint (DefaultDecl GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: DefaultDecl GhcPs -> Entry # setAnnotationAnchor :: DefaultDecl GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> DefaultDecl GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => DefaultDecl GhcPs -> EP w m (DefaultDecl GhcPs) #
ExactPrint (DerivClauseTys GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: DerivClauseTys GhcPs -> Entry # setAnnotationAnchor :: DerivClauseTys GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> DerivClauseTys GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => DerivClauseTys GhcPs -> EP w m (DerivClauseTys GhcPs) #
ExactPrint (DerivDecl GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: DerivDecl GhcPs -> Entry # setAnnotationAnchor :: DerivDecl GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> DerivDecl GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => DerivDecl GhcPs -> EP w m (DerivDecl GhcPs) #
ExactPrint (DerivStrategy GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: DerivStrategy GhcPs -> Entry # setAnnotationAnchor :: DerivStrategy GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> DerivStrategy GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => DerivStrategy GhcPs -> EP w m (DerivStrategy GhcPs) #
ExactPrint (DocDecl GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: DocDecl GhcPs -> Entry # setAnnotationAnchor :: DocDecl GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> DocDecl GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => DocDecl GhcPs -> EP w m (DocDecl GhcPs) #
ExactPrint (FamilyDecl GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: FamilyDecl GhcPs -> Entry # setAnnotationAnchor :: FamilyDecl GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> FamilyDecl GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => FamilyDecl GhcPs -> EP w m (FamilyDecl GhcPs) #
ExactPrint (ForeignDecl GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: ForeignDecl GhcPs -> Entry # setAnnotationAnchor :: ForeignDecl GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> ForeignDecl GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => ForeignDecl GhcPs -> EP w m (ForeignDecl GhcPs) #
ExactPrint (ForeignExport GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: ForeignExport GhcPs -> Entry # setAnnotationAnchor :: ForeignExport GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> ForeignExport GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => ForeignExport GhcPs -> EP w m (ForeignExport GhcPs) #
ExactPrint (ForeignImport GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: ForeignImport GhcPs -> Entry # setAnnotationAnchor :: ForeignImport GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> ForeignImport GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => ForeignImport GhcPs -> EP w m (ForeignImport GhcPs) #
ExactPrint (FunDep GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: FunDep GhcPs -> Entry # setAnnotationAnchor :: FunDep GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> FunDep GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => FunDep GhcPs -> EP w m (FunDep GhcPs) #
ExactPrint (HsDecl GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: HsDecl GhcPs -> Entry # setAnnotationAnchor :: HsDecl GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsDecl GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsDecl GhcPs -> EP w m (HsDecl GhcPs) #
ExactPrint (HsDerivingClause GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: HsDerivingClause GhcPs -> Entry # setAnnotationAnchor :: HsDerivingClause GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsDerivingClause GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsDerivingClause GhcPs -> EP w m (HsDerivingClause GhcPs) #
ExactPrint (InjectivityAnn GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: InjectivityAnn GhcPs -> Entry # setAnnotationAnchor :: InjectivityAnn GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> InjectivityAnn GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => InjectivityAnn GhcPs -> EP w m (InjectivityAnn GhcPs) #
ExactPrint (InstDecl GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: InstDecl GhcPs -> Entry # setAnnotationAnchor :: InstDecl GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> InstDecl GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => InstDecl GhcPs -> EP w m (InstDecl GhcPs) #
ExactPrint (RoleAnnotDecl GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: RoleAnnotDecl GhcPs -> Entry # setAnnotationAnchor :: RoleAnnotDecl GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> RoleAnnotDecl GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => RoleAnnotDecl GhcPs -> EP w m (RoleAnnotDecl GhcPs) #
ExactPrint (RuleBndr GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: RuleBndr GhcPs -> Entry # setAnnotationAnchor :: RuleBndr GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> RuleBndr GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => RuleBndr GhcPs -> EP w m (RuleBndr GhcPs) #
ExactPrint (RuleDecl GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: RuleDecl GhcPs -> Entry # setAnnotationAnchor :: RuleDecl GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> RuleDecl GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => RuleDecl GhcPs -> EP w m (RuleDecl GhcPs) #
ExactPrint (RuleDecls GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: RuleDecls GhcPs -> Entry # setAnnotationAnchor :: RuleDecls GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> RuleDecls GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => RuleDecls GhcPs -> EP w m (RuleDecls GhcPs) #
ExactPrint (SpliceDecl GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: SpliceDecl GhcPs -> Entry # setAnnotationAnchor :: SpliceDecl GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> SpliceDecl GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => SpliceDecl GhcPs -> EP w m (SpliceDecl GhcPs) #
ExactPrint (StandaloneKindSig GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: StandaloneKindSig GhcPs -> Entry # setAnnotationAnchor :: StandaloneKindSig GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> StandaloneKindSig GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => StandaloneKindSig GhcPs -> EP w m (StandaloneKindSig GhcPs) #
ExactPrint (TyClDecl GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: TyClDecl GhcPs -> Entry # setAnnotationAnchor :: TyClDecl GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> TyClDecl GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => TyClDecl GhcPs -> EP w m (TyClDecl GhcPs) #
ExactPrint (TyFamInstDecl GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: TyFamInstDecl GhcPs -> Entry # setAnnotationAnchor :: TyFamInstDecl GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> TyFamInstDecl GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => TyFamInstDecl GhcPs -> EP w m (TyFamInstDecl GhcPs) #
ExactPrint (WarnDecl GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: WarnDecl GhcPs -> Entry # setAnnotationAnchor :: WarnDecl GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> WarnDecl GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => WarnDecl GhcPs -> EP w m (WarnDecl GhcPs) #
ExactPrint (WarnDecls GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: WarnDecls GhcPs -> Entry # setAnnotationAnchor :: WarnDecls GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> WarnDecls GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => WarnDecls GhcPs -> EP w m (WarnDecls GhcPs) #
ExactPrint (DotFieldOcc GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: DotFieldOcc GhcPs -> Entry # setAnnotationAnchor :: DotFieldOcc GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> DotFieldOcc GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => DotFieldOcc GhcPs -> EP w m (DotFieldOcc GhcPs) #
ExactPrint (FieldLabelStrings GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: FieldLabelStrings GhcPs -> Entry # setAnnotationAnchor :: FieldLabelStrings GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> FieldLabelStrings GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => FieldLabelStrings GhcPs -> EP w m (FieldLabelStrings GhcPs) #
ExactPrint (HsCmd GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: HsCmd GhcPs -> Entry # setAnnotationAnchor :: HsCmd GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsCmd GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsCmd GhcPs -> EP w m (HsCmd GhcPs) #
ExactPrint (HsCmdTop GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: HsCmdTop GhcPs -> Entry # setAnnotationAnchor :: HsCmdTop GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsCmdTop GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsCmdTop GhcPs -> EP w m (HsCmdTop GhcPs) #
ExactPrint (HsExpr GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: HsExpr GhcPs -> Entry # setAnnotationAnchor :: HsExpr GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsExpr GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsExpr GhcPs -> EP w m (HsExpr GhcPs) #
ExactPrint (HsPragE GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: HsPragE GhcPs -> Entry # setAnnotationAnchor :: HsPragE GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsPragE GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsPragE GhcPs -> EP w m (HsPragE GhcPs) #
ExactPrint (HsTupArg GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: HsTupArg GhcPs -> Entry # setAnnotationAnchor :: HsTupArg GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsTupArg GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsTupArg GhcPs -> EP w m (HsTupArg GhcPs) #
ExactPrint (HsUntypedSplice GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: HsUntypedSplice GhcPs -> Entry # setAnnotationAnchor :: HsUntypedSplice GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsUntypedSplice GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsUntypedSplice GhcPs -> EP w m (HsUntypedSplice GhcPs) #
ExactPrint (LHsRecUpdFields GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: LHsRecUpdFields GhcPs -> Entry # setAnnotationAnchor :: LHsRecUpdFields GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> LHsRecUpdFields GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => LHsRecUpdFields GhcPs -> EP w m (LHsRecUpdFields GhcPs) #
ExactPrint (IE GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: IE GhcPs -> Entry # setAnnotationAnchor :: IE GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> IE GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => IE GhcPs -> EP w m (IE GhcPs) #
ExactPrint (IEWrappedName GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: IEWrappedName GhcPs -> Entry # setAnnotationAnchor :: IEWrappedName GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> IEWrappedName GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => IEWrappedName GhcPs -> EP w m (IEWrappedName GhcPs) #
ExactPrint (ImportDecl GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: ImportDecl GhcPs -> Entry # setAnnotationAnchor :: ImportDecl GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> ImportDecl GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => ImportDecl GhcPs -> EP w m (ImportDecl GhcPs) #
ExactPrint (HsOverLit GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: HsOverLit GhcPs -> Entry # setAnnotationAnchor :: HsOverLit GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsOverLit GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsOverLit GhcPs -> EP w m (HsOverLit GhcPs) #
ExactPrint (HsConPatTyArg GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: HsConPatTyArg GhcPs -> Entry # setAnnotationAnchor :: HsConPatTyArg GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsConPatTyArg GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsConPatTyArg GhcPs -> EP w m (HsConPatTyArg GhcPs) #
ExactPrint (Pat GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: Pat GhcPs -> Entry # setAnnotationAnchor :: Pat GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> Pat GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => Pat GhcPs -> EP w m (Pat GhcPs) #
ExactPrint (AmbiguousFieldOcc GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: AmbiguousFieldOcc GhcPs -> Entry # setAnnotationAnchor :: AmbiguousFieldOcc GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> AmbiguousFieldOcc GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => AmbiguousFieldOcc GhcPs -> EP w m (AmbiguousFieldOcc GhcPs) #
ExactPrint (ConDeclField GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: ConDeclField GhcPs -> Entry # setAnnotationAnchor :: ConDeclField GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> ConDeclField GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => ConDeclField GhcPs -> EP w m (ConDeclField GhcPs) #
ExactPrint (FieldOcc GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: FieldOcc GhcPs -> Entry # setAnnotationAnchor :: FieldOcc GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> FieldOcc GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => FieldOcc GhcPs -> EP w m (FieldOcc GhcPs) #
ExactPrint (HsForAllTelescope GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: HsForAllTelescope GhcPs -> Entry # setAnnotationAnchor :: HsForAllTelescope GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsForAllTelescope GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsForAllTelescope GhcPs -> EP w m (HsForAllTelescope GhcPs) #
ExactPrint (HsPatSigType GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: HsPatSigType GhcPs -> Entry # setAnnotationAnchor :: HsPatSigType GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsPatSigType GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsPatSigType GhcPs -> EP w m (HsPatSigType GhcPs) #
ExactPrint (HsSigType GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: HsSigType GhcPs -> Entry # setAnnotationAnchor :: HsSigType GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsSigType GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsSigType GhcPs -> EP w m (HsSigType GhcPs) #
ExactPrint (HsTyPat GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: HsTyPat GhcPs -> Entry # setAnnotationAnchor :: HsTyPat GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsTyPat GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsTyPat GhcPs -> EP w m (HsTyPat GhcPs) #
ExactPrint (HsType GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: HsType GhcPs -> Entry # setAnnotationAnchor :: HsType GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsType GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsType GhcPs -> EP w m (HsType GhcPs) #
ExactPrint a => ExactPrint (Maybe a) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: Maybe a -> Entry # setAnnotationAnchor :: Maybe a -> Anchor -> [TrailingAnn] -> EpAnnComments -> Maybe a # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => Maybe a -> EP w m (Maybe a) #
ExactPrint a => ExactPrint [a] |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: [a] -> Entry # setAnnotationAnchor :: [a] -> Anchor -> [TrailingAnn] -> EpAnnComments -> [a] # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => [a] -> EP w m [a] #
ExactPrint a => ExactPrint (WithHsDocIdentifiers a GhcPs) |

Instance details

Defined in Language.Haskell.GHC.ExactPrint.ExactPrint

Methods

getAnnotationEntry :: WithHsDocIdentifiers a GhcPs -> Entry #

setAnnotationAnchor :: WithHsDocIdentifiers a GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> WithHsDocIdentifiers a GhcPs #

exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => WithHsDocIdentifiers a GhcPs -> EP w m (WithHsDocIdentifiers a GhcPs) #

ExactPrint a => ExactPrint (LocatedAn NoEpAnns a) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: LocatedAn NoEpAnns a -> Entry # setAnnotationAnchor :: LocatedAn NoEpAnns a -> Anchor -> [TrailingAnn] -> EpAnnComments -> LocatedAn NoEpAnns a # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => LocatedAn NoEpAnns a -> EP w m (LocatedAn NoEpAnns a) #
ExactPrint (HsValBindsLR GhcPs GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: HsValBindsLR GhcPs GhcPs -> Entry # setAnnotationAnchor :: HsValBindsLR GhcPs GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsValBindsLR GhcPs GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsValBindsLR GhcPs GhcPs -> EP w m (HsValBindsLR GhcPs GhcPs) #
ExactPrint (PatSynBind GhcPs GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: PatSynBind GhcPs GhcPs -> Entry # setAnnotationAnchor :: PatSynBind GhcPs GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> PatSynBind GhcPs GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => PatSynBind GhcPs GhcPs -> EP w m (PatSynBind GhcPs GhcPs) #
ExactPrint body => ExactPrint (FamEqn GhcPs body) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: FamEqn GhcPs body -> Entry # setAnnotationAnchor :: FamEqn GhcPs body -> Anchor -> [TrailingAnn] -> EpAnnComments -> FamEqn GhcPs body # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => FamEqn GhcPs body -> EP w m (FamEqn GhcPs body) #
ExactPrint (GRHS GhcPs (LocatedA (HsCmd GhcPs))) |

Instance details

Defined in Language.Haskell.GHC.ExactPrint.ExactPrint

Methods

getAnnotationEntry :: GRHS GhcPs (LocatedA (HsCmd GhcPs)) -> Entry #

setAnnotationAnchor :: GRHS GhcPs (LocatedA (HsCmd GhcPs)) -> Anchor -> [TrailingAnn] -> EpAnnComments -> GRHS GhcPs (LocatedA (HsCmd GhcPs)) #

exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => GRHS GhcPs (LocatedA (HsCmd GhcPs)) -> EP w m (GRHS GhcPs (LocatedA (HsCmd GhcPs))) #

ExactPrint (GRHS GhcPs (LocatedA (HsExpr GhcPs))) |

Instance details

Defined in Language.Haskell.GHC.ExactPrint.ExactPrint

Methods

getAnnotationEntry :: GRHS GhcPs (LocatedA (HsExpr GhcPs)) -> Entry #

setAnnotationAnchor :: GRHS GhcPs (LocatedA (HsExpr GhcPs)) -> Anchor -> [TrailingAnn] -> EpAnnComments -> GRHS GhcPs (LocatedA (HsExpr GhcPs)) #

exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => GRHS GhcPs (LocatedA (HsExpr GhcPs)) -> EP w m (GRHS GhcPs (LocatedA (HsExpr GhcPs))) #

ExactPrint (GRHSs GhcPs (LocatedA (HsCmd GhcPs))) |

Instance details

Defined in Language.Haskell.GHC.ExactPrint.ExactPrint

Methods

getAnnotationEntry :: GRHSs GhcPs (LocatedA (HsCmd GhcPs)) -> Entry #

setAnnotationAnchor :: GRHSs GhcPs (LocatedA (HsCmd GhcPs)) -> Anchor -> [TrailingAnn] -> EpAnnComments -> GRHSs GhcPs (LocatedA (HsCmd GhcPs)) #

exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => GRHSs GhcPs (LocatedA (HsCmd GhcPs)) -> EP w m (GRHSs GhcPs (LocatedA (HsCmd GhcPs))) #

ExactPrint (GRHSs GhcPs (LocatedA (HsExpr GhcPs))) |

Instance details

Defined in Language.Haskell.GHC.ExactPrint.ExactPrint

Methods

getAnnotationEntry :: GRHSs GhcPs (LocatedA (HsExpr GhcPs)) -> Entry #

setAnnotationAnchor :: GRHSs GhcPs (LocatedA (HsExpr GhcPs)) -> Anchor -> [TrailingAnn] -> EpAnnComments -> GRHSs GhcPs (LocatedA (HsExpr GhcPs)) #

exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => GRHSs GhcPs (LocatedA (HsExpr GhcPs)) -> EP w m (GRHSs GhcPs (LocatedA (HsExpr GhcPs))) #

ExactPrint (Match GhcPs (LocatedA (HsCmd GhcPs))) |

Instance details

Defined in Language.Haskell.GHC.ExactPrint.ExactPrint

Methods

getAnnotationEntry :: Match GhcPs (LocatedA (HsCmd GhcPs)) -> Entry #

setAnnotationAnchor :: Match GhcPs (LocatedA (HsCmd GhcPs)) -> Anchor -> [TrailingAnn] -> EpAnnComments -> Match GhcPs (LocatedA (HsCmd GhcPs)) #

exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => Match GhcPs (LocatedA (HsCmd GhcPs)) -> EP w m (Match GhcPs (LocatedA (HsCmd GhcPs))) #

ExactPrint (Match GhcPs (LocatedA (HsExpr GhcPs))) |

Instance details

Defined in Language.Haskell.GHC.ExactPrint.ExactPrint

Methods

getAnnotationEntry :: Match GhcPs (LocatedA (HsExpr GhcPs)) -> Entry #

setAnnotationAnchor :: Match GhcPs (LocatedA (HsExpr GhcPs)) -> Anchor -> [TrailingAnn] -> EpAnnComments -> Match GhcPs (LocatedA (HsExpr GhcPs)) #

exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => Match GhcPs (LocatedA (HsExpr GhcPs)) -> EP w m (Match GhcPs (LocatedA (HsExpr GhcPs))) #

ExactPrint (MatchGroup GhcPs (LocatedA (HsCmd GhcPs))) |

Instance details

Defined in Language.Haskell.GHC.ExactPrint.ExactPrint

Methods

getAnnotationEntry :: MatchGroup GhcPs (LocatedA (HsCmd GhcPs)) -> Entry #

setAnnotationAnchor :: MatchGroup GhcPs (LocatedA (HsCmd GhcPs)) -> Anchor -> [TrailingAnn] -> EpAnnComments -> MatchGroup GhcPs (LocatedA (HsCmd GhcPs)) #

exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => MatchGroup GhcPs (LocatedA (HsCmd GhcPs)) -> EP w m (MatchGroup GhcPs (LocatedA (HsCmd GhcPs))) #

ExactPrint (MatchGroup GhcPs (LocatedA (HsExpr GhcPs))) |

Instance details

Defined in Language.Haskell.GHC.ExactPrint.ExactPrint

Methods

getAnnotationEntry :: MatchGroup GhcPs (LocatedA (HsExpr GhcPs)) -> Entry #

setAnnotationAnchor :: MatchGroup GhcPs (LocatedA (HsExpr GhcPs)) -> Anchor -> [TrailingAnn] -> EpAnnComments -> MatchGroup GhcPs (LocatedA (HsExpr GhcPs)) #

exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => MatchGroup GhcPs (LocatedA (HsExpr GhcPs)) -> EP w m (MatchGroup GhcPs (LocatedA (HsExpr GhcPs))) #

ExactPrint (ParStmtBlock GhcPs GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: ParStmtBlock GhcPs GhcPs -> Entry # setAnnotationAnchor :: ParStmtBlock GhcPs GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> ParStmtBlock GhcPs GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => ParStmtBlock GhcPs GhcPs -> EP w m (ParStmtBlock GhcPs GhcPs) #
ExactPrint (LocatedA body) => ExactPrint (HsFieldBind (LocatedA (AmbiguousFieldOcc GhcPs)) (LocatedA body)) |

Instance details

Defined in Language.Haskell.GHC.ExactPrint.ExactPrint

Methods

getAnnotationEntry :: HsFieldBind (LocatedA (AmbiguousFieldOcc GhcPs)) (LocatedA body) -> Entry #

setAnnotationAnchor :: HsFieldBind (LocatedA (AmbiguousFieldOcc GhcPs)) (LocatedA body) -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsFieldBind (LocatedA (AmbiguousFieldOcc GhcPs)) (LocatedA body) #

exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsFieldBind (LocatedA (AmbiguousFieldOcc GhcPs)) (LocatedA body) -> EP w m (HsFieldBind (LocatedA (AmbiguousFieldOcc GhcPs)) (LocatedA body)) #

ExactPrint body => ExactPrint (HsFieldBind (LocatedA (FieldOcc GhcPs)) body) |

Instance details

Defined in Language.Haskell.GHC.ExactPrint.ExactPrint

Methods

getAnnotationEntry :: HsFieldBind (LocatedA (FieldOcc GhcPs)) body -> Entry #

setAnnotationAnchor :: HsFieldBind (LocatedA (FieldOcc GhcPs)) body -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsFieldBind (LocatedA (FieldOcc GhcPs)) body #

exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsFieldBind (LocatedA (FieldOcc GhcPs)) body -> EP w m (HsFieldBind (LocatedA (FieldOcc GhcPs)) body) #

ExactPrint body => ExactPrint (HsFieldBind (LocatedAn NoEpAnns (FieldLabelStrings GhcPs)) body) |

Instance details

Defined in Language.Haskell.GHC.ExactPrint.ExactPrint

Methods

getAnnotationEntry :: HsFieldBind (LocatedAn NoEpAnns (FieldLabelStrings GhcPs)) body -> Entry #

setAnnotationAnchor :: HsFieldBind (LocatedAn NoEpAnns (FieldLabelStrings GhcPs)) body -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsFieldBind (LocatedAn NoEpAnns (FieldLabelStrings GhcPs)) body #

exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsFieldBind (LocatedAn NoEpAnns (FieldLabelStrings GhcPs)) body -> EP w m (HsFieldBind (LocatedAn NoEpAnns (FieldLabelStrings GhcPs)) body) #

ExactPrint body => ExactPrint (HsRecFields GhcPs body) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: HsRecFields GhcPs body -> Entry # setAnnotationAnchor :: HsRecFields GhcPs body -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsRecFields GhcPs body # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsRecFields GhcPs body -> EP w m (HsRecFields GhcPs body) #
ExactPrintTVFlag flag => ExactPrint (HsOuterTyVarBndrs flag GhcPs) |

Instance details

Defined in Language.Haskell.GHC.ExactPrint.ExactPrint

Methods

getAnnotationEntry :: HsOuterTyVarBndrs flag GhcPs -> Entry #

setAnnotationAnchor :: HsOuterTyVarBndrs flag GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsOuterTyVarBndrs flag GhcPs #

exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsOuterTyVarBndrs flag GhcPs -> EP w m (HsOuterTyVarBndrs flag GhcPs) #

ExactPrint a => ExactPrint (HsScaled GhcPs a) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: HsScaled GhcPs a -> Entry # setAnnotationAnchor :: HsScaled GhcPs a -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsScaled GhcPs a # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsScaled GhcPs a -> EP w m (HsScaled GhcPs a) #
ExactPrintTVFlag flag => ExactPrint (HsTyVarBndr flag GhcPs) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: HsTyVarBndr flag GhcPs -> Entry # setAnnotationAnchor :: HsTyVarBndr flag GhcPs -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsTyVarBndr flag GhcPs # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsTyVarBndr flag GhcPs -> EP w m (HsTyVarBndr flag GhcPs) #
ExactPrint body => ExactPrint (HsWildCardBndrs GhcPs body) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: HsWildCardBndrs GhcPs body -> Entry # setAnnotationAnchor :: HsWildCardBndrs GhcPs body -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsWildCardBndrs GhcPs body # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsWildCardBndrs GhcPs body -> EP w m (HsWildCardBndrs GhcPs body) #
ExactPrint (SourceText, RuleName) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: (SourceText, RuleName) -> Entry # setAnnotationAnchor :: (SourceText, RuleName) -> Anchor -> [TrailingAnn] -> EpAnnComments -> (SourceText, RuleName) # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => (SourceText, RuleName) -> EP w m (SourceText, RuleName) #
ExactPrint (SourceText, WarningCategory) |

Instance details

Defined in Language.Haskell.GHC.ExactPrint.ExactPrint

Methods

getAnnotationEntry :: (SourceText, WarningCategory) -> Entry #

setAnnotationAnchor :: (SourceText, WarningCategory) -> Anchor -> [TrailingAnn] -> EpAnnComments -> (SourceText, WarningCategory) #

exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => (SourceText, WarningCategory) -> EP w m (SourceText, WarningCategory) #

(ExactPrint (LocatedA (body GhcPs)), Anno (StmtLR GhcPs GhcPs (LocatedA (body GhcPs))) ~ SrcSpanAnnA, Anno [GenLocated SrcSpanAnnA (StmtLR GhcPs GhcPs (LocatedA (body GhcPs)))] ~ SrcSpanAnnL, ExactPrint (LocatedL [LocatedA (StmtLR GhcPs GhcPs (LocatedA (body GhcPs)))])) => ExactPrint (StmtLR GhcPs GhcPs (LocatedA (body GhcPs))) |

Instance details

Defined in Language.Haskell.GHC.ExactPrint.ExactPrint

Methods

getAnnotationEntry :: StmtLR GhcPs GhcPs (LocatedA (body GhcPs)) -> Entry #

setAnnotationAnchor :: StmtLR GhcPs GhcPs (LocatedA (body GhcPs)) -> Anchor -> [TrailingAnn] -> EpAnnComments -> StmtLR GhcPs GhcPs (LocatedA (body GhcPs)) #

exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => StmtLR GhcPs GhcPs (LocatedA (body GhcPs)) -> EP w m (StmtLR GhcPs GhcPs (LocatedA (body GhcPs))) #

(ExactPrint tm, ExactPrint ty, Outputable tm, Outputable ty) => ExactPrint (HsArg GhcPs tm ty) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.ExactPrint Methods getAnnotationEntry :: HsArg GhcPs tm ty -> Entry # setAnnotationAnchor :: HsArg GhcPs tm ty -> Anchor -> [TrailingAnn] -> EpAnnComments -> HsArg GhcPs tm ty # exact :: forall (m :: Type -> Type) w. (Monad m, Monoid w) => HsArg GhcPs tm ty -> EP w m (HsArg GhcPs tm ty) #

modifySmallestDeclWithM :: (HasDecls a, Monad m) => (SrcSpan -> m Bool) -> (LHsDecl GhcPs -> TransformT m ([LHsDecl GhcPs], r)) -> a -> TransformT m (a, Maybe r) #

Replace the smallest declaration whose SrcSpan satisfies the given condition with a new list of declarations.

For example, if you would like to move a where-clause-defined variable to the same level as its parent HsDecl, you could use this function.

When matching declaration is found in the sub-declarations of `a`, `Just r` is also returned with the new `a`. If no declaration matched, then `Nothing` is returned.

modifyMgMatchesT :: forall (m :: Type -> Type). Monad m => MatchGroup GhcPs (LHsExpr GhcPs) -> (LMatch GhcPs (LHsExpr GhcPs) -> TransformT m (LMatch GhcPs (LHsExpr GhcPs))) -> TransformT m (MatchGroup GhcPs (LHsExpr GhcPs)) #

Modify each LMatch in a MatchGroup

modifyMgMatchesT' :: Monad m => MatchGroup GhcPs (LHsExpr GhcPs) -> (LMatch GhcPs (LHsExpr GhcPs) -> TransformT m (LMatch GhcPs (LHsExpr GhcPs), r)) -> r -> (r -> r -> m r) -> TransformT m (MatchGroup GhcPs (LHsExpr GhcPs), r) #

Modify the each LMatch in a MatchGroup

modifySigWithM :: forall a (m :: Type -> Type). (HasDecls a, Monad m, ExactPrint a) => IdP GhcPs -> (LHsSigType GhcPs -> LHsSigType GhcPs) -> a -> TransformT m a #

Modify the type signature for the given IdP. This function handles splitting a multi-sig SigD into multiple SigD if the type signature is changed.

For example, update the type signature for `foo` from `Int` to `Bool`:

- foo :: Int + foo :: Bool
- foo, bar :: Int + bar :: Int + foo :: Bool
- foo, bar, baz :: Int + bar, baz :: Int + foo :: Bool

genAnchor1 :: Anchor #

setPrecedingLines :: LocatedAn t a -> Int -> Int -> LocatedAn t a #

addParens :: Bool -> NameAnn -> NameAnn #

addParensToCtxt :: Maybe EpaLocation -> AnnContext -> AnnContext #

modifyAnns :: LocatedAn a ast -> (a -> a) -> LocatedAn a ast #

removeComma :: SrcSpanAnnA -> SrcSpanAnnA #

# Helper function

eqSrcSpan :: SrcSpan -> SrcSpan -> Bool #

Equality on SrcSpan's. Ignores the (Maybe BufSpan) field of SrcSpan's.

epl :: Int -> EpaLocation #

epAnn :: SrcSpan -> ann -> EpAnn ann #

removeTrailingComma :: GenLocated SrcSpanAnnA ast -> GenLocated SrcSpanAnnA ast #

annotateParsedSource :: ParsedModule -> ParsedSource #

getAnnotatedParsedSourceRule :: Recorder (WithPriority Log) -> Rules () #

Get the latest version of the annotated parse source with comments.

data GetAnnotatedParsedSource #

Constructors

GetAnnotatedParsedSource |

#### Instances

Instances details

NFData GetAnnotatedParsedSource # |
Instance details Defined in Development.IDE.GHC.ExactPrint Methods rnf :: GetAnnotatedParsedSource -> () #
Generic GetAnnotatedParsedSource # |

Instance details

Defined in Development.IDE.GHC.ExactPrint

Associated Types

type Rep GetAnnotatedParsedSource |
Instance details Defined in Development.IDE.GHC.ExactPrint type Rep GetAnnotatedParsedSource = D1 ('MetaData "GetAnnotatedParsedSource" "Development.IDE.GHC.ExactPrint" "haskell-language-server-2.9.0.0-79WJNX2kCVW88Bk5rdgjgH-hls-refactor-plugin" 'False) (C1 ('MetaCons "GetAnnotatedParsedSource" 'PrefixI 'False) (U1 :: Type -> Type))

Methods

from :: GetAnnotatedParsedSource -> Rep GetAnnotatedParsedSource x #

to :: Rep GetAnnotatedParsedSource x -> GetAnnotatedParsedSource #

Show GetAnnotatedParsedSource # |
Instance details Defined in Development.IDE.GHC.ExactPrint Methods showsPrec :: Int -> GetAnnotatedParsedSource -> ShowS # show :: GetAnnotatedParsedSource -> String # showList :: [GetAnnotatedParsedSource] -> ShowS #
Eq GetAnnotatedParsedSource # |
Instance details Defined in Development.IDE.GHC.ExactPrint Methods (==) :: GetAnnotatedParsedSource -> GetAnnotatedParsedSource -> Bool # (/=) :: GetAnnotatedParsedSource -> GetAnnotatedParsedSource -> Bool #
Hashable GetAnnotatedParsedSource # |
Instance details Defined in Development.IDE.GHC.ExactPrint Methods hashWithSalt :: Int -> GetAnnotatedParsedSource -> Int # hash :: GetAnnotatedParsedSource -> Int #
type Rep GetAnnotatedParsedSource # |
Instance details Defined in Development.IDE.GHC.ExactPrint type Rep GetAnnotatedParsedSource = D1 ('MetaData "GetAnnotatedParsedSource" "Development.IDE.GHC.ExactPrint" "haskell-language-server-2.9.0.0-79WJNX2kCVW88Bk5rdgjgH-hls-refactor-plugin" 'False) (C1 ('MetaCons "GetAnnotatedParsedSource" 'PrefixI 'False) (U1 :: Type -> Type))
type RuleResult GetAnnotatedParsedSource # |
Instance details Defined in Development.IDE.GHC.ExactPrint type RuleResult GetAnnotatedParsedSource = ParsedSource

class (Data ast, Typeable l, Outputable l, Outputable ast) => ASTElement l ast | ast -> l where #

Minimal complete definition

parseAST, maybeParensAST

Methods

parseAST :: Parser (LocatedAn l ast) #

maybeParensAST :: LocatedAn l ast -> LocatedAn l ast #

graft :: Data a => SrcSpan -> LocatedAn l ast -> Graft (Either String) a #

Construct a `Graft`, replacing the node at the given `SrcSpan` with the given `Located ast`. The node at that position must already be a `Located ast`, or this is a no-op.

#### Instances

Instances details

ASTElement NameAnn RdrName # |
Instance details Defined in Development.IDE.GHC.ExactPrint Methods parseAST :: Parser (LocatedAn NameAnn RdrName) # maybeParensAST :: LocatedAn NameAnn RdrName -> LocatedAn NameAnn RdrName # graft :: Data a => SrcSpan -> LocatedAn NameAnn RdrName -> Graft (Either String) a #
p ~ GhcPs => ASTElement AnnListItem (HsDecl p) # |
Instance details Defined in Development.IDE.GHC.ExactPrint Methods parseAST :: Parser (LocatedAn AnnListItem (HsDecl p)) # maybeParensAST :: LocatedAn AnnListItem (HsDecl p) -> LocatedAn AnnListItem (HsDecl p) # graft :: Data a => SrcSpan -> LocatedAn AnnListItem (HsDecl p) -> Graft (Either String) a #
p ~ GhcPs => ASTElement AnnListItem (HsExpr p) # |
Instance details Defined in Development.IDE.GHC.ExactPrint Methods parseAST :: Parser (LocatedAn AnnListItem (HsExpr p)) # maybeParensAST :: LocatedAn AnnListItem (HsExpr p) -> LocatedAn AnnListItem (HsExpr p) # graft :: Data a => SrcSpan -> LocatedAn AnnListItem (HsExpr p) -> Graft (Either String) a #
p ~ GhcPs => ASTElement AnnListItem (ImportDecl p) # |
Instance details Defined in Development.IDE.GHC.ExactPrint Methods parseAST :: Parser (LocatedAn AnnListItem (ImportDecl p)) # maybeParensAST :: LocatedAn AnnListItem (ImportDecl p) -> LocatedAn AnnListItem (ImportDecl p) # graft :: Data a => SrcSpan -> LocatedAn AnnListItem (ImportDecl p) -> Graft (Either String) a #
p ~ GhcPs => ASTElement AnnListItem (Pat p) # |
Instance details Defined in Development.IDE.GHC.ExactPrint Methods parseAST :: Parser (LocatedAn AnnListItem (Pat p)) # maybeParensAST :: LocatedAn AnnListItem (Pat p) -> LocatedAn AnnListItem (Pat p) # graft :: Data a => SrcSpan -> LocatedAn AnnListItem (Pat p) -> Graft (Either String) a #
p ~ GhcPs => ASTElement AnnListItem (HsType p) # |
Instance details Defined in Development.IDE.GHC.ExactPrint Methods parseAST :: Parser (LocatedAn AnnListItem (HsType p)) # maybeParensAST :: LocatedAn AnnListItem (HsType p) -> LocatedAn AnnListItem (HsType p) # graft :: Data a => SrcSpan -> LocatedAn AnnListItem (HsType p) -> Graft (Either String) a #

newtype ExceptStringT (m :: Type -> Type) a #

Constructors

ExceptStringT |

Fields

- runExceptString :: ExceptT String m a

#### Instances

Instances details

MonadTrans ExceptStringT # |
Instance details Defined in Development.IDE.GHC.ExactPrint Methods lift :: Monad m => m a -> ExceptStringT m a #
MonadIO m => MonadIO (ExceptStringT m) # |
Instance details Defined in Development.IDE.GHC.ExactPrint Methods liftIO :: IO a -> ExceptStringT m a #
MonadZip m => MonadZip (ExceptStringT m) # |
Instance details Defined in Development.IDE.GHC.ExactPrint Methods mzip :: ExceptStringT m a -> ExceptStringT m b -> ExceptStringT m (a, b) # mzipWith :: (a -> b -> c) -> ExceptStringT m a -> ExceptStringT m b -> ExceptStringT m c # munzip :: ExceptStringT m (a, b) -> (ExceptStringT m a, ExceptStringT m b) #
Eq1 m => Eq1 (ExceptStringT m) # |
Instance details Defined in Development.IDE.GHC.ExactPrint Methods liftEq :: (a -> b -> Bool) -> ExceptStringT m a -> ExceptStringT m b -> Bool #
Ord1 m => Ord1 (ExceptStringT m) # |
Instance details Defined in Development.IDE.GHC.ExactPrint Methods liftCompare :: (a -> b -> Ordering) -> ExceptStringT m a -> ExceptStringT m b -> Ordering #
Read1 m => Read1 (ExceptStringT m) # |
Instance details Defined in Development.IDE.GHC.ExactPrint Methods liftReadsPrec :: (Int -> ReadS a) -> ReadS [a] -> Int -> ReadS (ExceptStringT m a) # liftReadList :: (Int -> ReadS a) -> ReadS [a] -> ReadS [ExceptStringT m a] # liftReadPrec :: ReadPrec a -> ReadPrec [a] -> ReadPrec (ExceptStringT m a) # liftReadListPrec :: ReadPrec a -> ReadPrec [a] -> ReadPrec [ExceptStringT m a] #
Show1 m => Show1 (ExceptStringT m) # |
Instance details Defined in Development.IDE.GHC.ExactPrint Methods liftShowsPrec :: (Int -> a -> ShowS) -> ([a] -> ShowS) -> Int -> ExceptStringT m a -> ShowS # liftShowList :: (Int -> a -> ShowS) -> ([a] -> ShowS) -> [ExceptStringT m a] -> ShowS #
Contravariant m => Contravariant (ExceptStringT m) # |
Instance details Defined in Development.IDE.GHC.ExactPrint Methods contramap :: (a' -> a) -> ExceptStringT m a -> ExceptStringT m a' # (>$) :: b -> ExceptStringT m b -> ExceptStringT m a #
Monad m => Alternative (ExceptStringT m) # |
Instance details Defined in Development.IDE.GHC.ExactPrint Methods empty :: ExceptStringT m a # (<|>) :: ExceptStringT m a -> ExceptStringT m a -> ExceptStringT m a # some :: ExceptStringT m a -> ExceptStringT m [a] # many :: ExceptStringT m a -> ExceptStringT m [a] #
Monad m => Applicative (ExceptStringT m) # |

Instance details

Defined in Development.IDE.GHC.ExactPrint

Methods

pure :: a -> ExceptStringT m a #

(<*>) :: ExceptStringT m (a -> b) -> ExceptStringT m a -> ExceptStringT m b #

liftA2 :: (a -> b -> c) -> ExceptStringT m a -> ExceptStringT m b -> ExceptStringT m c #

(*>) :: ExceptStringT m a -> ExceptStringT m b -> ExceptStringT m b #

(<*) :: ExceptStringT m a -> ExceptStringT m b -> ExceptStringT m a #

Functor m => Functor (ExceptStringT m) # |
Instance details Defined in Development.IDE.GHC.ExactPrint Methods fmap :: (a -> b) -> ExceptStringT m a -> ExceptStringT m b # (<$) :: a -> ExceptStringT m b -> ExceptStringT m a #
Monad m => Monad (ExceptStringT m) # |
Instance details Defined in Development.IDE.GHC.ExactPrint Methods (>>=) :: ExceptStringT m a -> (a -> ExceptStringT m b) -> ExceptStringT m b # (>>) :: ExceptStringT m a -> ExceptStringT m b -> ExceptStringT m b # return :: a -> ExceptStringT m a #
Monad m => MonadPlus (ExceptStringT m) # |
Instance details Defined in Development.IDE.GHC.ExactPrint Methods mzero :: ExceptStringT m a # mplus :: ExceptStringT m a -> ExceptStringT m a -> ExceptStringT m a #
Monad m => MonadFail (ExceptStringT m) # |
Instance details Defined in Development.IDE.GHC.ExactPrint Methods fail :: String -> ExceptStringT m a #
Foldable m => Foldable (ExceptStringT m) # |

Instance details

Defined in Development.IDE.GHC.ExactPrint

Methods

fold :: Monoid m0 => ExceptStringT m m0 -> m0 #

foldMap :: Monoid m0 => (a -> m0) -> ExceptStringT m a -> m0 #

foldMap' :: Monoid m0 => (a -> m0) -> ExceptStringT m a -> m0 #

foldr :: (a -> b -> b) -> b -> ExceptStringT m a -> b #

foldr' :: (a -> b -> b) -> b -> ExceptStringT m a -> b #

foldl :: (b -> a -> b) -> b -> ExceptStringT m a -> b #

foldl' :: (b -> a -> b) -> b -> ExceptStringT m a -> b #

foldr1 :: (a -> a -> a) -> ExceptStringT m a -> a #

foldl1 :: (a -> a -> a) -> ExceptStringT m a -> a #

toList :: ExceptStringT m a -> [a] #

null :: ExceptStringT m a -> Bool #

length :: ExceptStringT m a -> Int #

elem :: Eq a => a -> ExceptStringT m a -> Bool #

maximum :: Ord a => ExceptStringT m a -> a #

minimum :: Ord a => ExceptStringT m a -> a #

sum :: Num a => ExceptStringT m a -> a #

product :: Num a => ExceptStringT m a -> a #

(Read1 m, Read a) => Read (ExceptStringT m a) # |
Instance details Defined in Development.IDE.GHC.ExactPrint Methods readsPrec :: Int -> ReadS (ExceptStringT m a) # readList :: ReadS [ExceptStringT m a] # readPrec :: ReadPrec (ExceptStringT m a) # readListPrec :: ReadPrec [ExceptStringT m a] #
(Show1 m, Show a) => Show (ExceptStringT m a) # |
Instance details Defined in Development.IDE.GHC.ExactPrint Methods showsPrec :: Int -> ExceptStringT m a -> ShowS # show :: ExceptStringT m a -> String # showList :: [ExceptStringT m a] -> ShowS #
(Eq1 m, Eq a) => Eq (ExceptStringT m a) # |
Instance details Defined in Development.IDE.GHC.ExactPrint Methods (==) :: ExceptStringT m a -> ExceptStringT m a -> Bool # (/=) :: ExceptStringT m a -> ExceptStringT m a -> Bool #
(Ord1 m, Ord a) => Ord (ExceptStringT m a) # |

Instance details

Defined in Development.IDE.GHC.ExactPrint

Methods

compare :: ExceptStringT m a -> ExceptStringT m a -> Ordering #

(<) :: ExceptStringT m a -> ExceptStringT m a -> Bool #

(<=) :: ExceptStringT m a -> ExceptStringT m a -> Bool #

(>) :: ExceptStringT m a -> ExceptStringT m a -> Bool #

(>=) :: ExceptStringT m a -> ExceptStringT m a -> Bool #

max :: ExceptStringT m a -> ExceptStringT m a -> ExceptStringT m a #

min :: ExceptStringT m a -> ExceptStringT m a -> ExceptStringT m a #

data TransformT (m :: Type -> Type) a #

Monad transformer version of `Transform` monad

#### Instances

Instances details

MonadTrans TransformT |
Instance details Defined in Language.Haskell.GHC.ExactPrint.Transform Methods lift :: Monad m => m a -> TransformT m a #
Monad m => MonadReader () (TransformT m) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.Transform Methods ask :: TransformT m () # local :: (() -> ()) -> TransformT m a -> TransformT m a # reader :: (() -> a) -> TransformT m a #
Monad m => MonadState Int (TransformT m) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.Transform Methods get :: TransformT m Int # put :: Int -> TransformT m () # state :: (Int -> (a, Int)) -> TransformT m a #
Monad m => HasTransform (TransformT m) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.Transform Methods liftT :: Transform a -> TransformT m a #
Monad m => Applicative (TransformT m) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.Transform Methods pure :: a -> TransformT m a # (<*>) :: TransformT m (a -> b) -> TransformT m a -> TransformT m b # liftA2 :: (a -> b -> c) -> TransformT m a -> TransformT m b -> TransformT m c # (*>) :: TransformT m a -> TransformT m b -> TransformT m b # (<*) :: TransformT m a -> TransformT m b -> TransformT m a #
Functor m => Functor (TransformT m) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.Transform Methods fmap :: (a -> b) -> TransformT m a -> TransformT m b # (<$) :: a -> TransformT m b -> TransformT m a #
Monad m => Monad (TransformT m) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.Transform Methods (>>=) :: TransformT m a -> (a -> TransformT m b) -> TransformT m b # (>>) :: TransformT m a -> TransformT m b -> TransformT m b # return :: a -> TransformT m a #
MonadFail m => MonadFail (TransformT m) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.Transform Methods fail :: String -> TransformT m a #
Monad m => MonadWriter [String] (TransformT m) |
Instance details Defined in Language.Haskell.GHC.ExactPrint.Transform Methods writer :: (a, [String]) -> TransformT m a # tell :: [String] -> TransformT m () # listen :: TransformT m a -> TransformT m (a, [String]) # pass :: TransformT m (a, [String] -> [String]) -> TransformT m a #

data Log #

Constructors

LogShake Log |

#### Instances

Instances details

Show Log # |
Instance details Defined in Development.IDE.GHC.ExactPrint Methods showsPrec :: Int -> Log -> ShowS # show :: Log -> String # showList :: [Log] -> ShowS #
Pretty Log # |
Instance details Defined in Development.IDE.GHC.ExactPrint Methods pretty :: Log -> Doc ann # prettyList :: [Log] -> Doc ann #

# Orphan instances

Show (HsModule GhcPs) # |
Instance details Methods showsPrec :: Int -> HsModule GhcPs -> ShowS # show :: HsModule GhcPs -> String # showList :: [HsModule GhcPs] -> ShowS #