-- Hoogle documentation, generated by Haddock -- See Hoogle, http://www.haskell.org/hoogle/ -- | Specify refactorings to perform with apply-refact -- @package refact @version 0.3.0.1 module Refact.Types -- | A generic SrcSpan, usually this is converted immediately to a native -- representation. (For example a GHC SrcSpan or a HSE SrcSpan) data SrcSpan SrcSpan :: {-# UNPACK #-} !Int -> {-# UNPACK #-} !Int -> {-# UNPACK #-} !Int -> {-# UNPACK #-} !Int -> SrcSpan startLine :: SrcSpan -> {-# UNPACK #-} !Int startCol :: SrcSpan -> {-# UNPACK #-} !Int endLine :: SrcSpan -> {-# UNPACK #-} !Int endCol :: SrcSpan -> {-# UNPACK #-} !Int -- | Types of expressions which we are able to replace. data RType Expr :: RType Decl :: RType Type :: RType Pattern :: RType Stmt :: RType ModuleName :: RType Bind :: RType Match :: RType Import :: RType -- | Supported refactorings data Refactoring a Replace :: RType -> a -> [(String, a)] -> String -> Refactoring a -- | Type of expression to be replaced rtype :: Refactoring a -> RType -- | Expression to replace pos :: Refactoring a -> a -- | Substitutions to make subts :: Refactoring a -> [(String, a)] -- | Replacement template orig :: Refactoring a -> String ModifyComment :: a -> String -> Refactoring a -- | Expression to replace pos :: Refactoring a -> a newComment :: Refactoring a -> String InsertComment :: a -> String -> Refactoring a -- | Expression to replace pos :: Refactoring a -> a newComment :: Refactoring a -> String Delete :: RType -> a -> Refactoring a -- | Type of expression to be replaced rtype :: Refactoring a -> RType -- | Expression to replace pos :: Refactoring a -> a -- | Takes the position of a import decl and removes the as keyword RemoveAsKeyword :: a -> Refactoring a -- | Expression to replace pos :: Refactoring a -> a instance Typeable SrcSpan instance Typeable RType instance Typeable Refactoring instance Read SrcSpan instance Show SrcSpan instance Eq SrcSpan instance Ord SrcSpan instance Data SrcSpan instance Read RType instance Ord RType instance Show RType instance Eq RType instance Data RType instance Show a => Show (Refactoring a) instance Read a => Read (Refactoring a) instance Functor Refactoring instance Eq a => Eq (Refactoring a) instance Ord a => Ord (Refactoring a) instance Data a => Data (Refactoring a)