diff --git a/Language/Haskell/Tools/AST/Ann.hs b/Language/Haskell/Tools/AST/Ann.hs
--- a/Language/Haskell/Tools/AST/Ann.hs
+++ b/Language/Haskell/Tools/AST/Ann.hs
@@ -1,4 +1,5 @@
 {-# LANGUAGE AllowAmbiguousTypes, ConstraintKinds, DeriveDataTypeable, FlexibleContexts, FlexibleInstances, MultiParamTypeClasses, ScopedTypeVariables, StandaloneDeriving, TemplateHaskell, TypeApplications, TypeFamilies, UndecidableInstances #-}
+
 -- | Parts of AST representation for keeping extra data
 module Language.Haskell.Tools.AST.Ann where
 
@@ -14,6 +15,7 @@
 import {-# SOURCE #-} Language.Haskell.Tools.AST.Representation.Exprs as AST
 import {-# SOURCE #-} Language.Haskell.Tools.AST.Representation.Modules as AST
 import {-# SOURCE #-} Language.Haskell.Tools.AST.Representation.Names as AST
+import Language.Haskell.Tools.AST.Representation.Literals as AST
 
 -- * Annotation type resolution
 
@@ -58,59 +60,58 @@
 
 type SemanticInfo (domain :: *) (node :: * -> * -> *) = SemanticInfo' domain (SemaInfoClassify node)
 
-data SameInfoNameCls
-data SameInfoExprCls
-data SameInfoImportCls
-data SameInfoModuleCls
-data SameInfoDefaultCls
-data SameInfoWildcardCls
+data SemaInfoNameCls
+data SemaInfoLitCls
+data SemaInfoExprCls
+data SemaInfoImportCls
+data SemaInfoModuleCls
+data SemaInfoDefaultCls
+data SemaInfoWildcardCls
 
 type family SemaInfoClassify (node :: * -> * -> *) where
-  SemaInfoClassify UQualifiedName = SameInfoNameCls
-  SemaInfoClassify UExpr          = SameInfoExprCls
-  SemaInfoClassify UImportDecl    = SameInfoImportCls
-  SemaInfoClassify AST.UModule    = SameInfoModuleCls
-  SemaInfoClassify UFieldWildcard = SameInfoWildcardCls
-  SemaInfoClassify a             = SameInfoDefaultCls
+  SemaInfoClassify UQualifiedName = SemaInfoNameCls
+  SemaInfoClassify ULiteral       = SemaInfoLitCls
+  SemaInfoClassify UExpr          = SemaInfoExprCls
+  SemaInfoClassify UImportDecl    = SemaInfoImportCls
+  SemaInfoClassify AST.UModule    = SemaInfoModuleCls
+  SemaInfoClassify UFieldWildcard = SemaInfoWildcardCls
+  SemaInfoClassify a              = SemaInfoDefaultCls
 
 type family SemanticInfo' (domain :: *) (nodecls :: *)
 
-type instance SemanticInfo' (Dom n) SameInfoNameCls = NameInfo n
-type instance SemanticInfo' (Dom n) SameInfoExprCls = ScopeInfo
-type instance SemanticInfo' (Dom n) SameInfoImportCls = ImportInfo n
-type instance SemanticInfo' (Dom n) SameInfoModuleCls = ModuleInfo GHC.Name
-type instance SemanticInfo' (Dom n) SameInfoWildcardCls = ImplicitFieldInfo
-type instance SemanticInfo' (Dom n) SameInfoDefaultCls = NoSemanticInfo
+type instance SemanticInfo' (Dom n) SemaInfoNameCls = NameInfo n
+type instance SemanticInfo' (Dom n) SemaInfoLitCls = PreLiteralInfo
+type instance SemanticInfo' (Dom n) SemaInfoExprCls = ScopeInfo
+type instance SemanticInfo' (Dom n) SemaInfoImportCls = ImportInfo n
+type instance SemanticInfo' (Dom n) SemaInfoModuleCls = ModuleInfo GHC.Name
+type instance SemanticInfo' (Dom n) SemaInfoWildcardCls = ImplicitFieldInfo
+type instance SemanticInfo' (Dom n) SemaInfoDefaultCls = NoSemanticInfo
 
-type instance SemanticInfo' IdDom SameInfoNameCls = CNameInfo
-type instance SemanticInfo' IdDom SameInfoExprCls = ScopeInfo
-type instance SemanticInfo' IdDom SameInfoImportCls = ImportInfo GHC.Id
-type instance SemanticInfo' IdDom SameInfoModuleCls = ModuleInfo GHC.Id
-type instance SemanticInfo' IdDom SameInfoWildcardCls = ImplicitFieldInfo
-type instance SemanticInfo' IdDom SameInfoDefaultCls = NoSemanticInfo
+type instance SemanticInfo' IdDom SemaInfoNameCls = CNameInfo
+type instance SemanticInfo' IdDom SemaInfoExprCls = ScopeInfo
+type instance SemanticInfo' IdDom SemaInfoLitCls = LiteralInfo
+type instance SemanticInfo' IdDom SemaInfoImportCls = ImportInfo GHC.Id
+type instance SemanticInfo' IdDom SemaInfoModuleCls = ModuleInfo GHC.Id
+type instance SemanticInfo' IdDom SemaInfoWildcardCls = ImplicitFieldInfo
+type instance SemanticInfo' IdDom SemaInfoDefaultCls = NoSemanticInfo
 
 -- | A semantic domain for the AST. The semantic domain maps semantic information for
 -- the different types of nodes in the AST. The kind of semantic domain for an AST
--- depends on which stages of the compilation did it pass. However after transforming
--- the GHC representation to our AST, the domain keeps the same.
+-- depends on which stages of the compilation it passed. However after transforming
+-- the GHC representation to our AST, the domain stays the same.
 -- The domain is not applied to the AST elements that are generated while refactoring.
 type Domain d = ( Typeable d
                 , Data d
-                , SemanticInfo' d SameInfoDefaultCls ~ NoSemanticInfo
-                , Data (SemanticInfo' d SameInfoNameCls)
-                , Data (SemanticInfo' d SameInfoExprCls)
-                , Data (SemanticInfo' d SameInfoImportCls)
-                , Data (SemanticInfo' d SameInfoModuleCls)
-                , Data (SemanticInfo' d SameInfoWildcardCls)
-                , Show (SemanticInfo' d SameInfoNameCls)
-                , Show (SemanticInfo' d SameInfoExprCls)
-                , Show (SemanticInfo' d SameInfoImportCls)
-                , Show (SemanticInfo' d SameInfoModuleCls)
-                , Show (SemanticInfo' d SameInfoWildcardCls)
+                , SemanticInfo' d SemaInfoDefaultCls ~ NoSemanticInfo
+                , Data (SemanticInfo' d SemaInfoNameCls)
+                , Data (SemanticInfo' d SemaInfoLitCls)
+                , Data (SemanticInfo' d SemaInfoExprCls)
+                , Data (SemanticInfo' d SemaInfoImportCls)
+                , Data (SemanticInfo' d SemaInfoModuleCls)
+                , Data (SemanticInfo' d SemaInfoWildcardCls)
                 )
 
 type DomainWith e d = ( Data (SemanticInfo' d (SemaInfoClassify e))
-                      , Show (SemanticInfo' d (SemaInfoClassify e))
                       , Domain d
                       )
 
@@ -126,9 +127,6 @@
       , Data (SpanInfo stage)
       , Data (ListInfo stage)
       , Data (OptionalInfo stage)
-      , Show (SpanInfo stage)
-      , Show (ListInfo stage)
-      , Show (OptionalInfo stage)
       , HasRange (SpanInfo stage)
       , HasRange (ListInfo stage)
       , HasRange (OptionalInfo stage)
@@ -241,6 +239,9 @@
         , _element    :: elem dom stage -- ^ The original AST part
         }
 
+instance SourceInfo src => Eq (Ann elem dom src) where
+  a == b = getRange a == getRange b
+
 makeReferences ''Ann
 
 -- | A list of AST elements
@@ -340,12 +341,13 @@
 class ApplySemaChange cls where
   appSemaChange :: SemaTrf f dom1 dom2 -> SemanticInfo' dom1 cls -> f (SemanticInfo' dom2 cls)
 
-instance ApplySemaChange SameInfoNameCls where appSemaChange = trfSemaNameCls
-instance ApplySemaChange SameInfoExprCls where appSemaChange = trfSemaExprCls
-instance ApplySemaChange SameInfoImportCls where appSemaChange = trfSemaImportCls
-instance ApplySemaChange SameInfoModuleCls where appSemaChange = trfSemaModuleCls
-instance ApplySemaChange SameInfoWildcardCls where appSemaChange = trfSemaWildcardCls
-instance ApplySemaChange SameInfoDefaultCls where appSemaChange = trfSemaDefault
+instance ApplySemaChange SemaInfoNameCls where appSemaChange = trfSemaNameCls
+instance ApplySemaChange SemaInfoLitCls where appSemaChange = trfSemaLitCls
+instance ApplySemaChange SemaInfoExprCls where appSemaChange = trfSemaExprCls
+instance ApplySemaChange SemaInfoImportCls where appSemaChange = trfSemaImportCls
+instance ApplySemaChange SemaInfoModuleCls where appSemaChange = trfSemaModuleCls
+instance ApplySemaChange SemaInfoWildcardCls where appSemaChange = trfSemaWildcardCls
+instance ApplySemaChange SemaInfoDefaultCls where appSemaChange = trfSemaDefault
 
 -- | A class for traversing semantic information in an AST
 class ApplySemaChange (SemaInfoClassify a)
@@ -353,12 +355,13 @@
   semaTraverse :: Monad f => SemaTrf f dom1 dom2 -> a dom1 st -> f (a dom2 st)
 
 -- | A transformation on the possible semantic informations for a given domain
-data SemaTrf f dom1 dom2 = SemaTrf { trfSemaNameCls :: SemanticInfo' dom1 SameInfoNameCls -> f (SemanticInfo' dom2 SameInfoNameCls)
-                                   , trfSemaExprCls :: SemanticInfo' dom1 SameInfoExprCls -> f (SemanticInfo' dom2 SameInfoExprCls)
-                                   , trfSemaImportCls :: SemanticInfo' dom1 SameInfoImportCls -> f (SemanticInfo' dom2 SameInfoImportCls)
-                                   , trfSemaModuleCls :: SemanticInfo' dom1 SameInfoModuleCls -> f (SemanticInfo' dom2 SameInfoModuleCls)
-                                   , trfSemaWildcardCls :: SemanticInfo' dom1 SameInfoWildcardCls -> f (SemanticInfo' dom2 SameInfoWildcardCls)
-                                   , trfSemaDefault :: SemanticInfo' dom1 SameInfoDefaultCls -> f (SemanticInfo' dom2 SameInfoDefaultCls)
+data SemaTrf f dom1 dom2 = SemaTrf { trfSemaNameCls :: SemanticInfo' dom1 SemaInfoNameCls -> f (SemanticInfo' dom2 SemaInfoNameCls)
+                                   , trfSemaExprCls :: SemanticInfo' dom1 SemaInfoExprCls -> f (SemanticInfo' dom2 SemaInfoExprCls)
+                                   , trfSemaLitCls :: SemanticInfo' dom1 SemaInfoLitCls -> f (SemanticInfo' dom2 SemaInfoLitCls)
+                                   , trfSemaImportCls :: SemanticInfo' dom1 SemaInfoImportCls -> f (SemanticInfo' dom2 SemaInfoImportCls)
+                                   , trfSemaModuleCls :: SemanticInfo' dom1 SemaInfoModuleCls -> f (SemanticInfo' dom2 SemaInfoModuleCls)
+                                   , trfSemaWildcardCls :: SemanticInfo' dom1 SemaInfoWildcardCls -> f (SemanticInfo' dom2 SemaInfoWildcardCls)
+                                   , trfSemaDefault :: SemanticInfo' dom1 SemaInfoDefaultCls -> f (SemanticInfo' dom2 SemaInfoDefaultCls)
                                    }
 
 instance forall e . (ApplySemaChange (SemaInfoClassify e), SemanticTraversal e) => SemanticTraversal (Ann e) where
diff --git a/Language/Haskell/Tools/AST/Helpers.hs b/Language/Haskell/Tools/AST/Helpers.hs
--- a/Language/Haskell/Tools/AST/Helpers.hs
+++ b/Language/Haskell/Tools/AST/Helpers.hs
@@ -1,4 +1,5 @@
-{-# LANGUAGE FlexibleContexts, PatternSynonyms, RankNTypes, ScopedTypeVariables, TypeFamilies, TypeSynonymInstances, UndecidableInstances #-}
+{-# LANGUAGE FlexibleContexts, MonoLocalBinds, PatternSynonyms, RankNTypes, ScopedTypeVariables, UndecidableInstances #-}
+
 
 -- | Helper functions for using the AST.
 module Language.Haskell.Tools.AST.Helpers where
diff --git a/Language/Haskell/Tools/AST/Instances.hs b/Language/Haskell/Tools/AST/Instances.hs
--- a/Language/Haskell/Tools/AST/Instances.hs
+++ b/Language/Haskell/Tools/AST/Instances.hs
@@ -2,8 +2,7 @@
 module Language.Haskell.Tools.AST.Instances where
 
 import Language.Haskell.Tools.AST.Instances.Data ()
-import Language.Haskell.Tools.AST.Instances.Eq ()
 import Language.Haskell.Tools.AST.Instances.Generic ()
 import Language.Haskell.Tools.AST.Instances.SemanticTraversal ()
-import Language.Haskell.Tools.AST.Instances.Show ()
 import Language.Haskell.Tools.AST.Instances.SourceInfoTraversal ()
+import Language.Haskell.Tools.AST.Instances.ClassyPlate ()
diff --git a/Language/Haskell/Tools/AST/Instances/ClassyPlate.hs b/Language/Haskell/Tools/AST/Instances/ClassyPlate.hs
new file mode 100644
--- /dev/null
+++ b/Language/Haskell/Tools/AST/Instances/ClassyPlate.hs
@@ -0,0 +1,161 @@
+-- don't show warnings, Template Haskell generated code contains unused variables
+{-# LANGUAGE TypeApplications, TemplateHaskell, DataKinds, FlexibleInstances, MultiParamTypeClasses, FlexibleContexts, UndecidableInstances, TypeFamilies, AllowAmbiguousTypes, ScopedTypeVariables #-}
+{-# OPTIONS_GHC -fno-warn-unused-matches #-}
+
+-- | Generating instances for traversing the semantic information of the Haskell Representation
+module Language.Haskell.Tools.AST.Instances.ClassyPlate where
+
+import Data.Generics.ClassyPlate
+import Data.Generics.ClassyPlate.TH
+
+import Language.Haskell.Tools.AST.Ann
+import Language.Haskell.Tools.AST.Instances.Data
+import Language.Haskell.Tools.AST.Instances.Generic
+
+import Language.Haskell.Tools.AST.Representation.Binds
+import Language.Haskell.Tools.AST.Representation.Decls
+import Language.Haskell.Tools.AST.Representation.Exprs
+import Language.Haskell.Tools.AST.Representation.Kinds
+import Language.Haskell.Tools.AST.Representation.Literals
+import Language.Haskell.Tools.AST.Representation.Modules
+import Language.Haskell.Tools.AST.Representation.Names
+import Language.Haskell.Tools.AST.Representation.Patterns
+import Language.Haskell.Tools.AST.Representation.Stmts
+import Language.Haskell.Tools.AST.Representation.TH
+import Language.Haskell.Tools.AST.Representation.Types
+
+makeClassyPlateConfig OnlyDirect [Right '_annotation] ''Ann
+makeClassyPlateConfig OnlyDirect [Right '_annMaybeAnnot] ''AnnMaybeG
+makeClassyPlateConfig OnlyDirect [Right '_annListAnnot] ''AnnListG
+
+makeClassyPlateConfig OnlyDirect [] ''Maybe
+makeClassyPlateConfig OnlyDirect [] ''[]
+
+-- Modules
+makeClassyPlateConfig OnlyDirect [] ''UModule
+makeClassyPlateConfig OnlyDirect [] ''UModuleHead
+makeClassyPlateConfig OnlyDirect [] ''UExportSpecs
+makeClassyPlateConfig OnlyDirect [] ''UExportSpec
+makeClassyPlateConfig OnlyDirect [] ''UIESpec
+makeClassyPlateConfig OnlyDirect [] ''USubSpec
+makeClassyPlateConfig OnlyDirect [] ''UModulePragma
+makeClassyPlateConfig OnlyDirect [] ''UFilePragma
+makeClassyPlateConfig OnlyDirect [] ''UImportDecl
+makeClassyPlateConfig OnlyDirect [] ''UImportSpec
+makeClassyPlateConfig OnlyDirect [] ''UImportModifier
+makeClassyPlateConfig OnlyDirect [] ''UImportQualified
+makeClassyPlateConfig OnlyDirect [] ''UImportSource
+makeClassyPlateConfig OnlyDirect [] ''UImportSafe
+makeClassyPlateConfig OnlyDirect [] ''UTypeNamespace
+makeClassyPlateConfig OnlyDirect [] ''UImportRenaming
+
+-- Declarations
+makeClassyPlateConfig OnlyDirect [] ''UDecl
+makeClassyPlateConfig OnlyDirect [] ''UClassBody
+makeClassyPlateConfig OnlyDirect [] ''UClassElement
+makeClassyPlateConfig OnlyDirect [] ''UDeclHead
+makeClassyPlateConfig OnlyDirect [] ''UInstBody
+makeClassyPlateConfig OnlyDirect [] ''UInstBodyDecl
+makeClassyPlateConfig OnlyDirect [] ''UGadtConDecl
+makeClassyPlateConfig OnlyDirect [] ''UGadtConType
+makeClassyPlateConfig OnlyDirect [] ''UFieldWildcard
+makeClassyPlateConfig OnlyDirect [] ''UFunDeps
+makeClassyPlateConfig OnlyDirect [] ''UFunDep
+makeClassyPlateConfig OnlyDirect [] ''UConDecl
+makeClassyPlateConfig OnlyDirect [] ''UFieldDecl
+makeClassyPlateConfig OnlyDirect [] ''UDeriving
+makeClassyPlateConfig OnlyDirect [] ''UDeriveStrategy
+makeClassyPlateConfig OnlyDirect [] ''UInstanceRule
+makeClassyPlateConfig OnlyDirect [] ''UInstanceHead
+makeClassyPlateConfig OnlyDirect [] ''UTypeEqn
+makeClassyPlateConfig OnlyDirect [] ''UKindConstraint
+makeClassyPlateConfig OnlyDirect [] ''UTyVar
+makeClassyPlateConfig OnlyDirect [] ''UType
+makeClassyPlateConfig OnlyDirect [] ''UKind
+makeClassyPlateConfig OnlyDirect [] ''UContext
+makeClassyPlateConfig OnlyDirect [] ''UAssertion
+makeClassyPlateConfig OnlyDirect [] ''UExpr
+makeClassyPlateConfig OnlyDirect [] ''UCompStmt
+makeClassyPlateConfig OnlyDirect [] ''UValueBind
+makeClassyPlateConfig OnlyDirect [] ''UPattern
+makeClassyPlateConfig OnlyDirect [] ''UPatternField
+makeClassyPlateConfig OnlyDirect [] ''USplice
+makeClassyPlateConfig OnlyDirect [Right '_qqString] ''QQString
+makeClassyPlateConfig OnlyDirect [] ''UMatch
+makeClassyPlateConfig OnlyDirect [] ''URhs
+makeClassyPlateConfig OnlyDirect [] ''UGuardedRhs
+makeClassyPlateConfig OnlyDirect [] ''UFieldUpdate
+makeClassyPlateConfig OnlyDirect [] ''UBracket
+makeClassyPlateConfig OnlyDirect [] ''UTopLevelPragma
+makeClassyPlateConfig OnlyDirect [] ''URule
+makeClassyPlateConfig OnlyDirect [] ''URuleVar
+makeClassyPlateConfig OnlyDirect [] ''UAnnotationSubject
+makeClassyPlateConfig OnlyDirect [] ''UMinimalFormula
+makeClassyPlateConfig OnlyDirect [] ''UExprPragma
+makeClassyPlateConfig OnlyDirect [] ''USourceRange
+makeClassyPlateConfig OnlyDirect [Right '_numberInteger] ''Number
+makeClassyPlateConfig OnlyDirect [] ''UQuasiQuote
+makeClassyPlateConfig OnlyDirect [] ''URhsGuard
+makeClassyPlateConfig OnlyDirect [] ''ULocalBind
+makeClassyPlateConfig OnlyDirect [] ''ULocalBinds
+makeClassyPlateConfig OnlyDirect [] ''UFixitySignature
+makeClassyPlateConfig OnlyDirect [] ''UTypeSignature
+makeClassyPlateConfig OnlyDirect [] ''UListCompBody
+makeClassyPlateConfig OnlyDirect [] ''UTupSecElem
+makeClassyPlateConfig OnlyDirect [] ''UTypeFamily
+makeClassyPlateConfig OnlyDirect [] ''UTypeFamilySpec
+makeClassyPlateConfig OnlyDirect [] ''UInjectivityAnn
+makeClassyPlateConfig OnlyDirect [] ''UPatternSynonym
+makeClassyPlateConfig OnlyDirect [] ''UPatSynRhs
+makeClassyPlateConfig OnlyDirect [] ''UPatSynLhs
+makeClassyPlateConfig OnlyDirect [] ''UPatSynWhere
+makeClassyPlateConfig OnlyDirect [] ''UPatternTypeSignature
+makeClassyPlateConfig OnlyDirect [] ''URole
+makeClassyPlateConfig OnlyDirect [] ''UCmd
+makeClassyPlateConfig OnlyDirect [Right '_langExt] ''ULanguageExtension
+makeClassyPlateConfig OnlyDirect [] ''UMatchLhs
+makeClassyPlateConfig OnlyDirect [] ''UStmt'
+makeClassyPlateConfig OnlyDirect [] ''UAlt'
+makeClassyPlateConfig OnlyDirect [] ''UCaseRhs'
+makeClassyPlateConfig OnlyDirect [] ''UGuardedCaseRhs'
+makeClassyPlateConfig OnlyDirect [] ''UInlinePragma
+makeClassyPlateConfig OnlyDirect [] ''USpecializePragma
+makeClassyPlateConfig OnlyDirect [] ''UUnboxedSumPlaceHolder
+
+-- ULiteral
+makeClassyPlateConfig OnlyDirect [ Right '_charLitValue
+                        , Right '_stringLitValue
+                        , Right '_intLitValue
+                        , Right '_fracLitValue
+                        , Right '_intLitValue
+                        , Right '_intLitValue
+                        , Right '_floatLitValue
+                        , Right '_floatLitValue
+                        , Right '_charLitValue
+                        , Right '_stringLitValue
+                        ] ''ULiteral
+makeClassyPlateConfig OnlyDirect [ Right '_promotedIntValue
+                        , Right '_promotedStringValue
+                        ] ''UPromoted
+
+-- Base
+makeClassyPlateConfig OnlyDirect [] ''UOperator
+makeClassyPlateConfig OnlyDirect [] ''UName
+makeClassyPlateConfig OnlyDirect [] ''UQualifiedName
+makeClassyPlateConfig OnlyDirect [Right '_moduleNameString] ''UModuleName
+makeClassyPlateConfig OnlyDirect [Right '_simpleNameStr] ''UNamePart
+makeClassyPlateConfig OnlyDirect [Right '_stringNodeStr] ''UStringNode
+makeClassyPlateConfig OnlyDirect [] ''UDataOrNewtypeKeyword
+makeClassyPlateConfig OnlyDirect [] ''UDoKind
+makeClassyPlateConfig OnlyDirect [] ''TypeKeyword
+makeClassyPlateConfig OnlyDirect [] ''UOverlapPragma
+makeClassyPlateConfig OnlyDirect [] ''UCallConv
+makeClassyPlateConfig OnlyDirect [] ''UArrowAppl
+makeClassyPlateConfig OnlyDirect [] ''USafety
+makeClassyPlateConfig OnlyDirect [] ''UConlikeAnnot
+makeClassyPlateConfig OnlyDirect [] ''Assoc
+makeClassyPlateConfig OnlyDirect [Right '_precedenceValue] ''Precedence
+makeClassyPlateConfig OnlyDirect [Right '_lineNumber] ''LineNumber
+makeClassyPlateConfig OnlyDirect [] ''UPhaseControl
+makeClassyPlateConfig OnlyDirect [Right '_phaseNum] ''PhaseNumber
+makeClassyPlateConfig OnlyDirect [] ''PhaseInvert
diff --git a/Language/Haskell/Tools/AST/Instances/Data.hs b/Language/Haskell/Tools/AST/Instances/Data.hs
--- a/Language/Haskell/Tools/AST/Instances/Data.hs
+++ b/Language/Haskell/Tools/AST/Instances/Data.hs
@@ -1,5 +1,6 @@
 -- | Data instances for Haskell AST (used for generics)
-{-# LANGUAGE DeriveDataTypeable, FlexibleContexts, StandaloneDeriving, TypeFamilies, UndecidableInstances #-}
+{-# LANGUAGE DeriveDataTypeable, FlexibleContexts, GADTs, StandaloneDeriving, UndecidableInstances #-}
+
 module Language.Haskell.Tools.AST.Instances.Data () where
 
 import Data.Data
diff --git a/Language/Haskell/Tools/AST/Instances/Eq.hs b/Language/Haskell/Tools/AST/Instances/Eq.hs
deleted file mode 100644
--- a/Language/Haskell/Tools/AST/Instances/Eq.hs
+++ /dev/null
@@ -1,143 +0,0 @@
--- | Equality check of AST nodes that ignore the source and semantic information.
-{-# LANGUAGE FlexibleContexts, StandaloneDeriving #-}
-module Language.Haskell.Tools.AST.Instances.Eq () where
-
-import Language.Haskell.Tools.AST.Ann (Ann(..), AnnListG(..), AnnMaybeG(..))
-import Language.Haskell.Tools.AST.Representation.Binds
-import Language.Haskell.Tools.AST.Representation.Decls
-import Language.Haskell.Tools.AST.Representation.Exprs
-import Language.Haskell.Tools.AST.Representation.Kinds (UPromoted(..), UKind(..), UKindConstraint(..))
-import Language.Haskell.Tools.AST.Representation.Literals (ULiteral(..))
-import Language.Haskell.Tools.AST.Representation.Modules
-import Language.Haskell.Tools.AST.Representation.Names
-import Language.Haskell.Tools.AST.Representation.Patterns (UPatternField(..), UPattern(..))
-import Language.Haskell.Tools.AST.Representation.Stmts
-import Language.Haskell.Tools.AST.Representation.TH
-import Language.Haskell.Tools.AST.Representation.Types
-
--- Annotations
-instance (Eq (e dom stage)) => Eq (Ann e dom stage) where
-  Ann _ e1 == Ann _ e2 = e1 == e2
-
-instance (Eq (e dom stage)) => Eq (AnnMaybeG e dom stage) where
-  AnnMaybeG _ e1 == AnnMaybeG _ e2 = e1 == e2
-
-instance (Eq (e dom stage)) => Eq (AnnListG e dom stage) where
-  AnnListG _ e1 == AnnListG _ e2 = e1 == e2
-
--- Modules
-deriving instance Eq (UModule dom stage)
-deriving instance Eq (UModuleHead dom stage)
-deriving instance Eq (UExportSpecs dom stage)
-deriving instance Eq (UExportSpec dom stage)
-deriving instance Eq (UIESpec dom stage)
-deriving instance Eq (USubSpec dom stage)
-deriving instance Eq (UModulePragma dom stage)
-deriving instance Eq (UFilePragma dom stage)
-deriving instance Eq (UImportDecl dom stage)
-deriving instance Eq (UImportSpec dom stage)
-deriving instance Eq (UImportModifier dom stage)
-deriving instance Eq (UImportQualified dom stage)
-deriving instance Eq (UImportSource dom stage)
-deriving instance Eq (UImportSafe dom stage)
-deriving instance Eq (UTypeNamespace dom stage)
-deriving instance Eq (UImportRenaming dom stage)
-
--- Declarations
-deriving instance Eq (UDecl dom stage)
-deriving instance Eq (UClassBody dom stage)
-deriving instance Eq (UClassElement dom stage)
-deriving instance Eq (UDeclHead dom stage)
-deriving instance Eq (UInstBody dom stage)
-deriving instance Eq (UInstBodyDecl dom stage)
-deriving instance Eq (UGadtConDecl dom stage)
-deriving instance Eq (UGadtConType dom stage)
-deriving instance Eq (UFieldWildcard dom stage)
-deriving instance Eq (UFunDeps dom stage)
-deriving instance Eq (UFunDep dom stage)
-deriving instance Eq (UConDecl dom stage)
-deriving instance Eq (UFieldDecl dom stage)
-deriving instance Eq (UDeriving dom stage)
-deriving instance Eq (UDeriveStrategy dom stage)
-deriving instance Eq (UInstanceRule dom stage)
-deriving instance Eq (UInstanceHead dom stage)
-deriving instance Eq (UTypeEqn dom stage)
-deriving instance Eq (UKindConstraint dom stage)
-deriving instance Eq (UTyVar dom stage)
-deriving instance Eq (UType dom stage)
-deriving instance Eq (UKind dom stage)
-deriving instance Eq (UContext dom stage)
-deriving instance Eq (UAssertion dom stage)
-deriving instance Eq (UExpr dom stage)
-deriving instance Eq (expr dom stage) => Eq (UStmt' expr dom stage)
-deriving instance Eq (UCompStmt dom stage)
-deriving instance Eq (UValueBind dom stage)
-deriving instance Eq (UPattern dom stage)
-deriving instance Eq (UPatternField dom stage)
-deriving instance Eq (USplice dom stage)
-deriving instance Eq (QQString dom stage)
-deriving instance Eq (UMatch dom stage)
-deriving instance Eq (expr dom stage) => Eq (UAlt' expr dom stage)
-deriving instance Eq (URhs dom stage)
-deriving instance Eq (UGuardedRhs dom stage)
-deriving instance Eq (UFieldUpdate dom stage)
-deriving instance Eq (UBracket dom stage)
-deriving instance Eq (UTopLevelPragma dom stage)
-deriving instance Eq (URule dom stage)
-deriving instance Eq (URuleVar dom stage)
-deriving instance Eq (UAnnotationSubject dom stage)
-deriving instance Eq (UMinimalFormula dom stage)
-deriving instance Eq (UExprPragma dom stage)
-deriving instance Eq (USourceRange dom stage)
-deriving instance Eq (Number dom stage)
-deriving instance Eq (UQuasiQuote dom stage)
-deriving instance Eq (URhsGuard dom stage)
-deriving instance Eq (ULocalBind dom stage)
-deriving instance Eq (ULocalBinds dom stage)
-deriving instance Eq (UFixitySignature dom stage)
-deriving instance Eq (UTypeSignature dom stage)
-deriving instance Eq (UListCompBody dom stage)
-deriving instance Eq (UTupSecElem dom stage)
-deriving instance Eq (UTypeFamily dom stage)
-deriving instance Eq (UTypeFamilySpec dom stage)
-deriving instance Eq (UInjectivityAnn dom stage)
-deriving instance Eq (expr dom stage) => Eq (UCaseRhs' expr dom stage)
-deriving instance Eq (expr dom stage) => Eq (UGuardedCaseRhs' expr dom stage)
-deriving instance Eq (UPatternSynonym dom stage)
-deriving instance Eq (UPatSynRhs dom stage)
-deriving instance Eq (UPatSynLhs dom stage)
-deriving instance Eq (UPatSynWhere dom stage)
-deriving instance Eq (UPatternTypeSignature dom stage)
-deriving instance Eq (URole dom stage)
-deriving instance Eq (UCmd dom stage)
-deriving instance Eq (ULanguageExtension dom stage)
-deriving instance Eq (UMatchLhs dom stage)
-deriving instance Eq (UInlinePragma dom stage)
-deriving instance Eq (USpecializePragma dom stage)
-deriving instance Eq (UUnboxedSumPlaceHolder dom stage)
-
--- ULiteral
-deriving instance Eq (ULiteral dom stage)
-deriving instance Eq (k dom stage) => Eq (UPromoted k dom stage)
-
--- Base
-deriving instance Eq (UOperator dom stage)
-deriving instance Eq (UName dom stage)
-deriving instance Eq (UQualifiedName dom stage)
-deriving instance Eq (UModuleName dom stage)
-deriving instance Eq (UNamePart dom stage)
-deriving instance Eq (UStringNode dom stage)
-deriving instance Eq (UDataOrNewtypeKeyword dom stage)
-deriving instance Eq (UDoKind dom stage)
-deriving instance Eq (TypeKeyword dom stage)
-deriving instance Eq (UOverlapPragma dom stage)
-deriving instance Eq (UCallConv dom stage)
-deriving instance Eq (UArrowAppl dom stage)
-deriving instance Eq (USafety dom stage)
-deriving instance Eq (UConlikeAnnot dom stage)
-deriving instance Eq (Assoc dom stage)
-deriving instance Eq (Precedence dom stage)
-deriving instance Eq (LineNumber dom stage)
-deriving instance Eq (UPhaseControl dom stage)
-deriving instance Eq (PhaseNumber dom stage)
-deriving instance Eq (PhaseInvert dom stage)
diff --git a/Language/Haskell/Tools/AST/Instances/Generic.hs b/Language/Haskell/Tools/AST/Instances/Generic.hs
--- a/Language/Haskell/Tools/AST/Instances/Generic.hs
+++ b/Language/Haskell/Tools/AST/Instances/Generic.hs
@@ -1,5 +1,6 @@
 -- | Generic instance for Haskell AST representation
-{-# LANGUAGE DeriveGeneric, FlexibleContexts, StandaloneDeriving, TypeFamilies, UndecidableInstances #-}
+{-# LANGUAGE DeriveGeneric, FlexibleContexts, GADTs, StandaloneDeriving, UndecidableInstances #-}
+
 module Language.Haskell.Tools.AST.Instances.Generic () where
 
 import GHC.Generics (Generic(..))
diff --git a/Language/Haskell/Tools/AST/Instances/SemanticTraversal.hs b/Language/Haskell/Tools/AST/Instances/SemanticTraversal.hs
--- a/Language/Haskell/Tools/AST/Instances/SemanticTraversal.hs
+++ b/Language/Haskell/Tools/AST/Instances/SemanticTraversal.hs
@@ -1,6 +1,7 @@
 -- don't show warnings, Template Haskell generated code contains unused variables
-{-# OPTIONS_GHC -fno-warn-unused-matches #-}
 {-# LANGUAGE TemplateHaskell #-}
+{-# OPTIONS_GHC -fno-warn-unused-matches #-}
+
 -- | Generating instances for traversing the semantic information of the Haskell Representation
 module Language.Haskell.Tools.AST.Instances.SemanticTraversal () where
 
diff --git a/Language/Haskell/Tools/AST/Instances/Show.hs b/Language/Haskell/Tools/AST/Instances/Show.hs
deleted file mode 100644
--- a/Language/Haskell/Tools/AST/Instances/Show.hs
+++ /dev/null
@@ -1,144 +0,0 @@
--- | Show instance for Haskell AST representation ignoring source and semantic information
-{-# LANGUAGE FlexibleContexts, StandaloneDeriving #-}
-module Language.Haskell.Tools.AST.Instances.Show () where
-
-import Language.Haskell.Tools.AST.Ann (Ann(..), AnnListG(..), AnnMaybeG(..))
-import Language.Haskell.Tools.AST.Representation.Binds
-import Language.Haskell.Tools.AST.Representation.Decls
-import Language.Haskell.Tools.AST.Representation.Exprs
-import Language.Haskell.Tools.AST.Representation.Kinds (UPromoted(..), UKind(..), UKindConstraint(..))
-import Language.Haskell.Tools.AST.Representation.Literals (ULiteral(..))
-import Language.Haskell.Tools.AST.Representation.Modules
-import Language.Haskell.Tools.AST.Representation.Names
-import Language.Haskell.Tools.AST.Representation.Patterns (UPatternField(..), UPattern(..))
-import Language.Haskell.Tools.AST.Representation.Stmts
-import Language.Haskell.Tools.AST.Representation.TH
-import Language.Haskell.Tools.AST.Representation.Types
-
--- Annotations
-instance (Show (e dom stage)) => Show (Ann e dom stage) where
-  show (Ann _ e) = show e
-
-instance (Show (e dom stage)) => Show (AnnMaybeG e dom stage) where
-  show (AnnMaybeG _ e) = show e
-
-instance (Show (e dom stage)) => Show (AnnListG e dom stage) where
-  show (AnnListG _ e) = show e
-
--- Modules
-deriving instance Show (UModule dom stage)
-deriving instance Show (UModuleHead dom stage)
-deriving instance Show (UExportSpecs dom stage)
-deriving instance Show (UExportSpec dom stage)
-deriving instance Show (UIESpec dom stage)
-deriving instance Show (USubSpec dom stage)
-deriving instance Show (UModulePragma dom stage)
-deriving instance Show (UFilePragma dom stage)
-deriving instance Show (UImportDecl dom stage)
-deriving instance Show (UImportSpec dom stage)
-deriving instance Show (UImportModifier dom stage)
-deriving instance Show (UImportQualified dom stage)
-deriving instance Show (UImportSource dom stage)
-deriving instance Show (UImportSafe dom stage)
-deriving instance Show (UTypeNamespace dom stage)
-deriving instance Show (UImportRenaming dom stage)
-
--- Declarations
-deriving instance Show (UDecl dom stage)
-deriving instance Show (UClassBody dom stage)
-deriving instance Show (UClassElement dom stage)
-deriving instance Show (UDeclHead dom stage)
-deriving instance Show (UInstBody dom stage)
-deriving instance Show (UInstBodyDecl dom stage)
-deriving instance Show (UGadtConDecl dom stage)
-deriving instance Show (UGadtConType dom stage)
-deriving instance Show (UFieldWildcard dom stage)
-deriving instance Show (UFunDeps dom stage)
-deriving instance Show (UFunDep dom stage)
-deriving instance Show (UConDecl dom stage)
-deriving instance Show (UFieldDecl dom stage)
-deriving instance Show (UDeriving dom stage)
-deriving instance Show (UDeriveStrategy dom stage)
-deriving instance Show (UInstanceRule dom stage)
-deriving instance Show (UInstanceHead dom stage)
-deriving instance Show (UTypeEqn dom stage)
-deriving instance Show (UKindConstraint dom stage)
-deriving instance Show (UTyVar dom stage)
-deriving instance Show (UType dom stage)
-deriving instance Show (UKind dom stage)
-deriving instance Show (UContext dom stage)
-deriving instance Show (UAssertion dom stage)
-deriving instance Show (UExpr dom stage)
-deriving instance Show (expr dom stage) => Show (UStmt' expr dom stage)
-deriving instance Show (UCompStmt dom stage)
-deriving instance Show (UValueBind dom stage)
-deriving instance Show (UPattern dom stage)
-deriving instance Show (UPatternField dom stage)
-deriving instance Show (USplice dom stage)
-deriving instance Show (QQString dom stage)
-deriving instance Show (UMatch dom stage)
-deriving instance Show (expr dom stage) => Show (UAlt' expr dom stage)
-deriving instance Show (URhs dom stage)
-deriving instance Show (UGuardedRhs dom stage)
-deriving instance Show (UFieldUpdate dom stage)
-deriving instance Show (UBracket dom stage)
-deriving instance Show (UTopLevelPragma dom stage)
-deriving instance Show (URule dom stage)
-deriving instance Show (URuleVar dom stage)
-deriving instance Show (UAnnotationSubject dom stage)
-deriving instance Show (UMinimalFormula dom stage)
-deriving instance Show (UExprPragma dom stage)
-deriving instance Show (USourceRange dom stage)
-deriving instance Show (Number dom stage)
-deriving instance Show (UQuasiQuote dom stage)
-deriving instance Show (URhsGuard dom stage)
-deriving instance Show (ULocalBind dom stage)
-deriving instance Show (ULocalBinds dom stage)
-deriving instance Show (UFixitySignature dom stage)
-deriving instance Show (UTypeSignature dom stage)
-deriving instance Show (UListCompBody dom stage)
-deriving instance Show (UTupSecElem dom stage)
-deriving instance Show (UTypeFamily dom stage)
-deriving instance Show (UTypeFamilySpec dom stage)
-deriving instance Show (UInjectivityAnn dom stage)
-deriving instance Show (expr dom stage) => Show (UCaseRhs' expr dom stage)
-deriving instance Show (expr dom stage) => Show (UGuardedCaseRhs' expr dom stage)
-deriving instance Show (UPatternSynonym dom stage)
-deriving instance Show (UPatSynRhs dom stage)
-deriving instance Show (UPatSynLhs dom stage)
-deriving instance Show (UPatSynWhere dom stage)
-deriving instance Show (UPatternTypeSignature dom stage)
-deriving instance Show (URole dom stage)
-deriving instance Show (UCmd dom stage)
-deriving instance Show (ULanguageExtension dom stage)
-deriving instance Show (UMatchLhs dom stage)
-deriving instance Show (UInlinePragma dom stage)
-deriving instance Show (USpecializePragma dom stage)
-deriving instance Show (UUnboxedSumPlaceHolder dom stage)
-
-
--- ULiteral
-deriving instance Show (ULiteral dom stage)
-deriving instance Show (k dom stage) => Show (UPromoted k dom stage)
-
--- Base
-deriving instance Show (UOperator dom stage)
-deriving instance Show (UName dom stage)
-deriving instance Show (UQualifiedName dom stage)
-deriving instance Show (UModuleName dom stage)
-deriving instance Show (UNamePart dom stage)
-deriving instance Show (UStringNode dom stage)
-deriving instance Show (UDataOrNewtypeKeyword dom stage)
-deriving instance Show (UDoKind dom stage)
-deriving instance Show (TypeKeyword dom stage)
-deriving instance Show (UOverlapPragma dom stage)
-deriving instance Show (UCallConv dom stage)
-deriving instance Show (UArrowAppl dom stage)
-deriving instance Show (USafety dom stage)
-deriving instance Show (UConlikeAnnot dom stage)
-deriving instance Show (Assoc dom stage)
-deriving instance Show (Precedence dom stage)
-deriving instance Show (LineNumber dom stage)
-deriving instance Show (UPhaseControl dom stage)
-deriving instance Show (PhaseNumber dom stage)
-deriving instance Show (PhaseInvert dom stage)
diff --git a/Language/Haskell/Tools/AST/Instances/SourceInfoTraversal.hs b/Language/Haskell/Tools/AST/Instances/SourceInfoTraversal.hs
--- a/Language/Haskell/Tools/AST/Instances/SourceInfoTraversal.hs
+++ b/Language/Haskell/Tools/AST/Instances/SourceInfoTraversal.hs
@@ -1,6 +1,7 @@
 -- don't show warnings, Template Haskell generated code contains unused variables
-{-# OPTIONS_GHC -fno-warn-unused-matches #-}
 {-# LANGUAGE TemplateHaskell #-}
+{-# OPTIONS_GHC -fno-warn-unused-matches #-}
+
 -- | Generating instances for traversing the semantic information of the Haskell Representation
 module Language.Haskell.Tools.AST.Instances.SourceInfoTraversal () where
 
diff --git a/Language/Haskell/Tools/AST/MakeASTReferences.hs b/Language/Haskell/Tools/AST/MakeASTReferences.hs
--- a/Language/Haskell/Tools/AST/MakeASTReferences.hs
+++ b/Language/Haskell/Tools/AST/MakeASTReferences.hs
@@ -1,4 +1,5 @@
-{-# LANGUAGE LambdaCase, TemplateHaskellQuotes #-}
+{-# LANGUAGE LambdaCase, TemplateHaskellQuotes #-}
+
 -- | Contains a transformation to alter the references generated by the template haskell 
 -- function @makeReferences@.
 module Language.Haskell.Tools.AST.MakeASTReferences where
diff --git a/Language/Haskell/Tools/AST/References.hs b/Language/Haskell/Tools/AST/References.hs
--- a/Language/Haskell/Tools/AST/References.hs
+++ b/Language/Haskell/Tools/AST/References.hs
@@ -1,6 +1,7 @@
 -- don't show warnings, Template Haskell generated code contains unused variables
-{-# OPTIONS_GHC -fno-warn-unused-matches #-}
 {-# LANGUAGE FlexibleContexts, TemplateHaskell #-}
+{-# OPTIONS_GHC -fno-warn-unused-matches #-}
+
 -- | Generated references for AST elements.
 module Language.Haskell.Tools.AST.References where
 
diff --git a/Language/Haskell/Tools/AST/Representation/Binds.hs-boot b/Language/Haskell/Tools/AST/Representation/Binds.hs-boot
--- a/Language/Haskell/Tools/AST/Representation/Binds.hs-boot
+++ b/Language/Haskell/Tools/AST/Representation/Binds.hs-boot
@@ -1,4 +1,5 @@
 {-# LANGUAGE RoleAnnotations #-}
+
 module Language.Haskell.Tools.AST.Representation.Binds where
 
 type role ULocalBind nominal nominal
diff --git a/Language/Haskell/Tools/AST/Representation/Exprs.hs-boot b/Language/Haskell/Tools/AST/Representation/Exprs.hs-boot
--- a/Language/Haskell/Tools/AST/Representation/Exprs.hs-boot
+++ b/Language/Haskell/Tools/AST/Representation/Exprs.hs-boot
@@ -1,4 +1,5 @@
 {-# LANGUAGE RoleAnnotations #-}
+
 module Language.Haskell.Tools.AST.Representation.Exprs where
 
 type role UExpr nominal nominal
diff --git a/Language/Haskell/Tools/AST/Representation/Modules.hs-boot b/Language/Haskell/Tools/AST/Representation/Modules.hs-boot
--- a/Language/Haskell/Tools/AST/Representation/Modules.hs-boot
+++ b/Language/Haskell/Tools/AST/Representation/Modules.hs-boot
@@ -1,4 +1,5 @@
 {-# LANGUAGE RoleAnnotations #-}
+
 module Language.Haskell.Tools.AST.Representation.Modules where
 
 type role UModule nominal nominal
diff --git a/Language/Haskell/Tools/AST/Representation/Names.hs b/Language/Haskell/Tools/AST/Representation/Names.hs
--- a/Language/Haskell/Tools/AST/Representation/Names.hs
+++ b/Language/Haskell/Tools/AST/Representation/Names.hs
@@ -1,5 +1,6 @@
 
-{-# LANGUAGE MultiParamTypeClasses, TypeFamilies, TypeSynonymInstances #-}
+{-# LANGUAGE MonoLocalBinds #-}
+
 
 -- | Simple AST elements of Haskell
 module Language.Haskell.Tools.AST.Representation.Names where
diff --git a/Language/Haskell/Tools/AST/Representation/Names.hs-boot b/Language/Haskell/Tools/AST/Representation/Names.hs-boot
--- a/Language/Haskell/Tools/AST/Representation/Names.hs-boot
+++ b/Language/Haskell/Tools/AST/Representation/Names.hs-boot
@@ -1,5 +1,6 @@
 {-# LANGUAGE RoleAnnotations #-}
+
 module Language.Haskell.Tools.AST.Representation.Names where
 
 type role UQualifiedName nominal nominal
-data UQualifiedName dom stage
+data UQualifiedName dom stage
diff --git a/Language/Haskell/Tools/AST/Representation/TH.hs-boot b/Language/Haskell/Tools/AST/Representation/TH.hs-boot
--- a/Language/Haskell/Tools/AST/Representation/TH.hs-boot
+++ b/Language/Haskell/Tools/AST/Representation/TH.hs-boot
@@ -1,4 +1,5 @@
 {-# LANGUAGE RoleAnnotations #-}
+
 module Language.Haskell.Tools.AST.Representation.TH where
 
 type role USplice nominal nominal
diff --git a/Language/Haskell/Tools/AST/Representation/Types.hs-boot b/Language/Haskell/Tools/AST/Representation/Types.hs-boot
--- a/Language/Haskell/Tools/AST/Representation/Types.hs-boot
+++ b/Language/Haskell/Tools/AST/Representation/Types.hs-boot
@@ -1,4 +1,5 @@
 {-# LANGUAGE RoleAnnotations #-}
+
 -- | Representation of Haskell types
 module Language.Haskell.Tools.AST.Representation.Types where
 
diff --git a/Language/Haskell/Tools/AST/SemaInfoClasses.hs b/Language/Haskell/Tools/AST/SemaInfoClasses.hs
--- a/Language/Haskell/Tools/AST/SemaInfoClasses.hs
+++ b/Language/Haskell/Tools/AST/SemaInfoClasses.hs
@@ -1,6 +1,7 @@
-{-# LANGUAGE ConstraintKinds, FlexibleContexts, FlexibleInstances, TypeFamilies, UndecidableInstances #-}
-module Language.Haskell.Tools.AST.SemaInfoClasses (module Language.Haskell.Tools.AST.SemaInfoClasses, UsageSpec(..)) where
+{-# LANGUAGE ConstraintKinds, FlexibleContexts, FlexibleInstances, GADTs, UndecidableInstances #-}
 
+module Language.Haskell.Tools.AST.SemaInfoClasses (module Language.Haskell.Tools.AST.SemaInfoClasses, getInstances, UsageSpec(..)) where
+
 import GHC
 import Id as GHC (Id, idName)
 
@@ -9,9 +10,13 @@
 import Language.Haskell.Tools.AST.Ann as AST
 import Language.Haskell.Tools.AST.Representation.Exprs as AST (UFieldWildcard, UExpr)
 import Language.Haskell.Tools.AST.Representation.Modules as AST (UImportDecl, UModule)
-import Language.Haskell.Tools.AST.Representation.Names as AST (UQualifiedName)
+import Language.Haskell.Tools.AST.Representation.Names as AST (UName(..), UQualifiedName)
+import Language.Haskell.Tools.AST.Representation.Literals as AST (ULiteral)
 import Language.Haskell.Tools.AST.SemaInfoTypes as AST
 
+semanticsLitType :: Ann ULiteral IdDom st -> GHC.Type
+semanticsLitType lit = lit ^. annotation & semanticInfo & literalType
+
 -- * Information about names
 
 -- | Domains that have semantic information for names
@@ -30,6 +35,22 @@
 instance HasNameInfo dom => HasNameInfo' (Ann UQualifiedName dom st) where
   semanticsName = semanticsName . (^. annotation&semanticInfo)
 
+instance HasNameInfo dom => HasNameInfo' (Ann UName dom st) where
+  semanticsName = semanticsName . _simpleName . _element
+
+-- | Domains that have semantic information for literals
+type HasLiteralInfo dom = (Domain dom, HasLiteralInfo' (SemanticInfo dom ULiteral))
+
+-- | Info of types
+class HasLiteralInfo' si where
+  semanticsLiteralType :: si -> GHC.Type
+
+instance HasLiteralInfo' LiteralInfo where
+  semanticsLiteralType = (^. literalType)
+
+instance HasLiteralInfo dom => HasLiteralInfo' (Ann ULiteral dom st) where
+  semanticsLiteralType = semanticsLiteralType . (^. annotation&semanticInfo)
+
 -- * Information about typed names
 
 type HasIdInfo dom = (Domain dom, HasIdInfo' (SemanticInfo dom UQualifiedName))
@@ -44,6 +65,9 @@
 instance HasIdInfo dom => HasIdInfo' (Ann UQualifiedName dom st) where
   semanticsId = semanticsId . (^. annotation&semanticInfo)
 
+instance HasIdInfo dom => HasIdInfo' (Ann UName dom st) where
+  semanticsId = semanticsId . _simpleName . _element
+
 -- * Fixity information
 
 type HasFixityInfo dom = (Domain dom, HasFixityInfo' (SemanticInfo dom UQualifiedName))
@@ -115,32 +139,28 @@
   semanticsDynFlags :: si -> GHC.DynFlags
   isBootModule :: si -> Bool
   semanticsImplicitImports :: si -> [GHC.Name]
-  semanticsPrelOrphanInsts :: si -> [ClsInst]
-  semanticsPrelFamInsts :: si -> [FamInst]
+  semanticsPrelTransMods :: si -> [Module]
 
 instance HasModuleInfo' (AST.ModuleInfo GHC.Name) where
   semanticsModule = (^. defModuleName)
   semanticsDynFlags = (^. defDynFlags)
   isBootModule = (^. defIsBootModule)
   semanticsImplicitImports = (^? implicitNames&traversal&pName)
-  semanticsPrelOrphanInsts = (^. prelOrphanInsts)
-  semanticsPrelFamInsts = (^. prelFamInsts)
+  semanticsPrelTransMods = (^. prelTransMods)
 
 instance HasModuleInfo' (AST.ModuleInfo GHC.Id) where
   semanticsModule = (^. defModuleName)
   semanticsDynFlags = (^. defDynFlags)
   isBootModule = (^. defIsBootModule)
   semanticsImplicitImports = map idName . (^? implicitNames&traversal&pName)
-  semanticsPrelOrphanInsts = (^. prelOrphanInsts)
-  semanticsPrelFamInsts = (^. prelFamInsts)
+  semanticsPrelTransMods = (^. prelTransMods)
 
 instance HasModuleInfo dom => HasModuleInfo' (Ann UModule dom st) where
   semanticsModule = semanticsModule . (^. annotation&semanticInfo)
   semanticsDynFlags = semanticsDynFlags . (^. annotation&semanticInfo)
   isBootModule = isBootModule . (^. annotation&semanticInfo)
   semanticsImplicitImports = semanticsImplicitImports . (^. annotation&semanticInfo)
-  semanticsPrelOrphanInsts = semanticsPrelOrphanInsts . (^. annotation&semanticInfo)
-  semanticsPrelFamInsts = semanticsPrelFamInsts . (^. annotation&semanticInfo)
+  semanticsPrelTransMods = semanticsPrelTransMods . (^. annotation&semanticInfo)
 
 -- * Information about imports
 
@@ -150,29 +170,25 @@
   semanticsImportedModule :: si -> GHC.Module
   semanticsAvailable :: si -> [GHC.Name]
   semanticsImported :: si -> [GHC.Name]
-  semanticsOrphanInsts :: si -> [ClsInst]
-  semanticsFamInsts :: si -> [FamInst]
+  semanticsTransMods :: si -> [Module]
 
 instance HasImportInfo' (AST.ImportInfo GHC.Name) where
   semanticsImportedModule = (^. importedModule)
   semanticsAvailable = (^. availableNames)
   semanticsImported = (^? importedNames&traversal&pName)
-  semanticsOrphanInsts = (^. importedOrphanInsts)
-  semanticsFamInsts = (^. importedFamInsts)
+  semanticsTransMods = (^. importTransMods)
 
 instance HasImportInfo' (AST.ImportInfo GHC.Id) where
   semanticsImportedModule = (^. importedModule)
   semanticsAvailable = map idName . (^. availableNames)
   semanticsImported = map idName . (^? importedNames&traversal&pName)
-  semanticsOrphanInsts = (^. importedOrphanInsts)
-  semanticsFamInsts = (^. importedFamInsts)
+  semanticsTransMods = (^. importTransMods)
 
 instance HasImportInfo dom => HasImportInfo' (Ann UImportDecl dom st) where
   semanticsImportedModule = semanticsImportedModule . (^. annotation&semanticInfo)
   semanticsAvailable = semanticsAvailable . (^. annotation&semanticInfo)
   semanticsImported = semanticsImported . (^. annotation&semanticInfo)
-  semanticsOrphanInsts = semanticsOrphanInsts . (^. annotation&semanticInfo)
-  semanticsFamInsts = semanticsFamInsts . (^. annotation&semanticInfo)
+  semanticsTransMods = semanticsTransMods . (^. annotation&semanticInfo)
 
 -- * Information about implicitly bounded fields
 
diff --git a/Language/Haskell/Tools/AST/SemaInfoTypes.hs b/Language/Haskell/Tools/AST/SemaInfoTypes.hs
--- a/Language/Haskell/Tools/AST/SemaInfoTypes.hs
+++ b/Language/Haskell/Tools/AST/SemaInfoTypes.hs
@@ -1,57 +1,57 @@
-{-# LANGUAGE BangPatterns, DeriveDataTypeable, FlexibleContexts, StandaloneDeriving, TemplateHaskell, TypeSynonymInstances, UndecidableInstances #-}
+{-# LANGUAGE BangPatterns, DeriveDataTypeable, FlexibleContexts, StandaloneDeriving, TemplateHaskell, TypeSynonymInstances, UndecidableInstances, DeriveTraversable #-}
+
 module Language.Haskell.Tools.AST.SemaInfoTypes
   ( -- types
     NoSemanticInfo, ScopeInfo, NameInfo, CNameInfo, ModuleInfo, ImportInfo, ImplicitFieldInfo
-  , Scope, UsageSpec(..)
+  , Scope, UsageSpec(..), LiteralInfo(..), PreLiteralInfo(..)
     -- references
   , exprScopedLocals, nameScopedLocals, nameIsDefined, nameInfo, ambiguousName, nameLocation
   , implicitName, cnameScopedLocals, cnameIsDefined, cnameInfo, cnameFixity
   , defModuleName, defDynFlags, defIsBootModule, implicitNames, importedModule, availableNames
-  , importedNames, implicitFieldBindings, importedOrphanInsts, importedFamInsts, prelOrphanInsts
-  , prelFamInsts
+  , importedNames, implicitFieldBindings, prelTransMods, importTransMods, literalType
     -- creator functions
   , mkNoSemanticInfo, mkScopeInfo, mkNameInfo, mkAmbiguousNameInfo, mkImplicitNameInfo, mkCNameInfo
   , mkModuleInfo, mkImportInfo, mkImplicitFieldInfo
   -- utils
   , PName(..), pName, pNameParent
+  , getInstances
   ) where
 
 import BasicTypes as GHC
 import DynFlags as GHC
 import FamInstEnv as GHC
+import qualified GHC
 import Id as GHC
+import Var
 import InstEnv as GHC
 import Module as GHC
 import Name as GHC
-import Outputable as GHC
 import RdrName as GHC
 import SrcLoc as GHC
+import Type as GHC
+import HscTypes as GHC
+import CoAxiom as GHC
 
+import Data.Maybe
 import Data.Data as Data
-import Data.List
-
 import Control.Reference
+import Control.Monad
+import Control.Monad.IO.Class
 
+import Outputable
+
 type Scope = [[(Name, Maybe [UsageSpec], Maybe Name)]]
 
 data UsageSpec = UsageSpec { usageQualified :: Bool
                            , usageQualifier :: String
                            , usageAs :: String
                            }
-  deriving (Eq, Data)
-
-instance Outputable UsageSpec where
-  ppr (UsageSpec q useQ asQ)
-    = GHC.text $ (if q then "qualified " else "") ++ "as "
-        ++ (if useQ == asQ || q then asQ else asQ ++ " or " ++ useQ)
-  pprPrec _ (UsageSpec q useQ asQ)
-    = GHC.text $ (if q then "qualified " else "") ++ "as "
-        ++ (if useQ == asQ || q then asQ else asQ ++ " or " ++ useQ)
+  deriving Data
 
 -- | Semantic info type for any node not
 -- carrying additional semantic information
 data NoSemanticInfo = NoSemanticInfo
-  deriving (Eq, Data)
+  deriving Data
 
 mkNoSemanticInfo :: NoSemanticInfo
 mkNoSemanticInfo = NoSemanticInfo
@@ -59,12 +59,22 @@
 -- | Info for expressions that tells which definitions are in scope
 data ScopeInfo = ScopeInfo { _exprScopedLocals :: Scope
                            }
-  deriving (Eq, Data)
+  deriving Data
 
 -- | Creates the information about the definitions in scope
 mkScopeInfo :: Scope -> ScopeInfo
 mkScopeInfo = ScopeInfo
 
+data PreLiteralInfo = RealLiteralInfo { _realLiteralType :: Type
+                                      }
+                    | PreLiteralInfo { _preLiteralLoc :: SrcSpan
+                                     }
+  deriving Data
+
+data LiteralInfo = LiteralInfo { _literalType :: Type
+                               }
+  deriving Data
+
 -- | Info corresponding to a name
 data NameInfo n = NameInfo { _nameScopedLocals :: Scope
                            , _nameIsDefined :: Bool
@@ -81,7 +91,7 @@
                                    , _nameLocation :: SrcSpan
                                    }
 
-  deriving (Eq, Data)
+  deriving (Data, Functor, Foldable, Traversable)
 
 -- | Creates semantic information for an unambiguous name
 mkNameInfo :: Scope -> Bool -> n -> NameInfo n
@@ -101,7 +111,7 @@
                            , _cnameInfo :: Id
                            , _cnameFixity :: Maybe GHC.Fixity
                            }
-  deriving (Eq, Data)
+  deriving Data
 
 -- | Create a typed name semantic information
 mkCNameInfo :: Scope -> Bool -> Id -> Maybe GHC.Fixity -> CNameInfo
@@ -111,17 +121,16 @@
   = PName { _pName :: n
           , _pNameParent :: Maybe n
           }
-  deriving Data
+  deriving (Data, Functor, Foldable, Traversable)
 
 -- | Info for the module element
 data ModuleInfo n = ModuleInfo { _defModuleName :: GHC.Module
                                , _defDynFlags :: DynFlags -- ^ The compilation flags that are set up when the module was compiled
                                , _defIsBootModule :: Bool -- ^ True if this module is created from a hs-boot file
                                , _implicitNames :: [PName n] -- ^ implicitly imported names
-                               , _prelOrphanInsts :: [ClsInst] -- ^ Class instances implicitly passed from Prelude.
-                               , _prelFamInsts :: [FamInst] -- ^ Family instances implicitly passed from Prelude.
+                               , _prelTransMods :: [GHC.Module] -- ^ Modules imported transitively.
                                }
-  deriving Data
+  deriving (Data, Functor, Foldable, Traversable)
 
 instance Data DynFlags where
   gunfold _ _ _ = error "Cannot construct dyn flags"
@@ -133,132 +142,56 @@
 
 -- | Creates semantic information for the module element.
 -- Strict in the list of implicitely imported, orphan and family instances.
-mkModuleInfo :: GHC.Module -> DynFlags -> Bool -> [PName n] -> [ClsInst] -> [FamInst] -> ModuleInfo n
+mkModuleInfo :: GHC.Module -> DynFlags -> Bool -> [PName n] -> [GHC.Module] -> ModuleInfo n
 -- the calculate of these fields involves a big parts of the GHC state and it causes a space leak
 -- if not evaluated strictly
-mkModuleInfo mod dfs boot !imported !orphan !family = ModuleInfo mod dfs boot imported orphan family
+mkModuleInfo mod dfs boot !imported deps = ModuleInfo mod dfs boot imported deps
 
 -- | Info corresponding to an import declaration
 data ImportInfo n = ImportInfo { _importedModule :: GHC.Module -- ^ The name and package of the imported module
                                , _availableNames :: [n] -- ^ Names available from the imported module
                                , _importedNames :: [PName n] -- ^ Names actually imported from the module.
-                               , _importedOrphanInsts :: [ClsInst] -- ^ Class instances implicitly passed.
-                               , _importedFamInsts :: [FamInst] -- ^ Family instances implicitly passed.
+                               , _importTransMods :: [GHC.Module] -- ^ Modules imported transitively.
                                }
-  deriving Data
+  deriving (Data, Functor, Foldable, Traversable)
 
 deriving instance Data FamInst
 deriving instance Data FamFlavor
 
 -- | Creates semantic information for an import declaration
 -- Strict in the list of the used and imported declarations, orphan and family instances.
-mkImportInfo :: GHC.Module -> [n] -> [PName n] -> [ClsInst] -> [FamInst] -> ImportInfo n
+mkImportInfo :: GHC.Module -> [n] -> [PName n] -> [GHC.Module] -> ImportInfo n
 -- the calculate of these fields involves a big parts of the GHC state and it causes a space leak
 -- if not evaluated strictly
-mkImportInfo mod !names !imported !orphan !family = ImportInfo mod names imported orphan family
+mkImportInfo mod !names !imported deps = ImportInfo mod names imported deps
 
+-- | Gets the class and family instances from a module.
+getInstances :: [Module] -> GHC.Ghc ([ClsInst], [FamInst])
+getInstances mods = do
+  env <- GHC.getSession
+  eps <- liftIO $ hscEPS env
+  let homePkgs = catMaybes $ map (lookupHpt (hsc_HPT env) . GHC.moduleName) mods
+      (hptInsts, hptFamInsts) = hptInstances env (`elem` map GHC.moduleName mods)
+      isFromMods inst = maybe False (`elem` mods) $ nameModule_maybe $ Var.varName $ is_dfun inst
+      famIsFromMods inst = maybe False (`elem` mods) $ nameModule_maybe $ co_ax_name $ fi_axiom inst
+      epsInsts = filter isFromMods $ instEnvElts $ eps_inst_env eps
+      epsFamInsts = filter famIsFromMods $ famInstEnvElts $ eps_fam_inst_env eps
+  return (hptInsts ++ epsInsts, hptFamInsts ++ epsFamInsts)
+
 -- | Info corresponding to an record-wildcard
 data ImplicitFieldInfo = ImplicitFieldInfo { _implicitFieldBindings :: [(Name, Name)] -- ^ The implicitly bounded names
                                            }
-  deriving (Eq, Data)
+  deriving Data
 
 -- | Creates semantic information for a wildcard field binding
 mkImplicitFieldInfo :: [(Name, Name)] -> ImplicitFieldInfo
 mkImplicitFieldInfo = ImplicitFieldInfo
 
-instance Show ScopeInfo where
-  show (ScopeInfo locals) = "(ScopeInfo " ++ showSDocUnsafe (ppr locals) ++ ")"
-
-instance Outputable n => Show (NameInfo n) where
-  show (NameInfo locals defined nameInfo)
-    = "(NameInfo " ++ showSDocUnsafe (ppr locals) ++ " " ++ show defined ++ " "
-        ++ showSDocUnsafe (ppr nameInfo) ++ ")"
-  show (AmbiguousNameInfo locals defined nameInfo span)
-    = "(AmbiguousNameInfo " ++ showSDocUnsafe (ppr locals) ++ " " ++ show defined ++ " "
-        ++ showSDocUnsafe (ppr nameInfo) ++ " " ++ show span ++ ")"
-  show (ImplicitNameInfo locals defined nameInfo span)
-    = "(ImplicitNameInfo " ++ showSDocUnsafe (ppr locals) ++ " " ++ show defined ++ " "
-        ++ showSDocUnsafe (ppr nameInfo) ++ " " ++ show span ++ ")"
-
-instance Show CNameInfo where
-  show (CNameInfo locals defined nameInfo fixity)
-    = "(CNameInfo " ++ showSDocUnsafe (ppr locals) ++ " " ++ show defined ++ " "
-        ++ showSDocUnsafe (ppr nameInfo) ++ showSDocUnsafe (ppr fixity) ++ ")"
-
-instance Outputable n => Show (PName n) where
-  show (PName n (Just parent))
-    = showSDocUnsafe (ppr n) ++ "[in " ++ showSDocUnsafe (ppr parent) ++ "]"
-  show (PName n Nothing) = showSDocUnsafe (ppr n)
-
-instance Outputable n => Show (ModuleInfo n) where
-  show (ModuleInfo mod _ isboot imp clsInsts famInsts)
-    = "(ModuleInfo " ++ showSDocUnsafe (ppr mod) ++ " " ++ show isboot ++ " " ++ show imp ++ " "
-          ++ showSDocUnsafe (ppr clsInsts) ++ " " ++ showSDocUnsafe (ppr famInsts) ++ ")"
-
-instance Outputable n => Show (ImportInfo n) where
-  show (ImportInfo mod avail imported clsInsts famInsts)
-    = "(ImportInfo " ++ showSDocUnsafe (ppr mod) ++ " " ++ showSDocUnsafe (ppr avail) ++ " "
-        ++ show imported ++ " " ++ showSDocUnsafe (ppr clsInsts) ++ " "
-        ++ showSDocUnsafe (ppr famInsts) ++ ")"
-
-instance Show ImplicitFieldInfo where
-  show (ImplicitFieldInfo bnds)
-    = "(ImplicitFieldInfo [" ++ concat (intersperse "," (map showImplicitFld bnds)) ++ "])"
-    where showImplicitFld (from, to) = showSDocUnsafe (ppr from) ++ "->" ++ showSDocUnsafe (ppr to)
-
-instance Show NoSemanticInfo where
-  show NoSemanticInfo = "NoSemanticInfo"
-
 makeReferences ''PName
-makeReferences ''NoSemanticInfo
 makeReferences ''ScopeInfo
 makeReferences ''NameInfo
 makeReferences ''CNameInfo
 makeReferences ''ModuleInfo
 makeReferences ''ImportInfo
 makeReferences ''ImplicitFieldInfo
-
-instance Functor NameInfo where
-  fmap f = nameInfo .- f
-
-instance Functor PName where
-  fmap f (PName n p) = PName (f n) (fmap f p)
-
-instance Functor ModuleInfo where
-  fmap f = implicitNames .- fmap (fmap f)
-
-instance Functor ImportInfo where
-  fmap f (ImportInfo mod avail imps clsInsts famInsts)
-    = ImportInfo mod (fmap f avail) (fmap (fmap f) imps) clsInsts famInsts
-
-instance Foldable NameInfo where
-  foldMap f si = maybe mempty f (si ^? nameInfo)
-
-instance Foldable ModuleInfo where
-  foldMap f si = foldMap (foldMap f) (si ^. implicitNames)
-
-instance Foldable ImportInfo where
-  foldMap f si = foldMap f (((si ^. availableNames)
-                   ++ (si ^? importedNames & traversal & (pName &+& pNameParent & just) )))
-
-instance Foldable PName where
-  foldMap f (PName n p) = f n `mappend` foldMap f p
-
-instance Traversable PName where
-  traverse f (PName n p) = PName <$> f n <*> traverse f p
-
-instance Traversable NameInfo where
-  traverse f (NameInfo locals defined nameInfo) = NameInfo locals defined <$> f nameInfo
-  traverse _ (AmbiguousNameInfo locals defined nameInfo span)
-    = pure $ AmbiguousNameInfo locals defined nameInfo span
-  traverse _ (ImplicitNameInfo locals defined nameInfo span)
-    = pure $ ImplicitNameInfo locals defined nameInfo span
-
-instance Traversable ModuleInfo where
-  traverse f (ModuleInfo mod dfs isboot imp clsInsts famInsts)
-    = ModuleInfo mod dfs isboot <$> traverse (traverse f) imp <*> pure clsInsts <*> pure famInsts
-
-instance Traversable ImportInfo where
-  traverse f (ImportInfo mod avail imps clsInsts famInsts)
-    = ImportInfo mod <$> traverse f avail <*> traverse (traverse f) imps <*> pure clsInsts
-                     <*> pure famInsts
+makeReferences ''LiteralInfo
diff --git a/Language/Haskell/Tools/AST/TH/SemanticTraversal.hs b/Language/Haskell/Tools/AST/TH/SemanticTraversal.hs
--- a/Language/Haskell/Tools/AST/TH/SemanticTraversal.hs
+++ b/Language/Haskell/Tools/AST/TH/SemanticTraversal.hs
@@ -1,4 +1,5 @@
 {-# LANGUAGE LambdaCase, TemplateHaskellQuotes #-}
+
 -- | Generating instances for traversal on semantic information
 module Language.Haskell.Tools.AST.TH.SemanticTraversal where
 
diff --git a/Language/Haskell/Tools/AST/TH/SourceInfoTraversal.hs b/Language/Haskell/Tools/AST/TH/SourceInfoTraversal.hs
--- a/Language/Haskell/Tools/AST/TH/SourceInfoTraversal.hs
+++ b/Language/Haskell/Tools/AST/TH/SourceInfoTraversal.hs
@@ -1,4 +1,5 @@
 {-# LANGUAGE LambdaCase, TemplateHaskellQuotes #-}
+
 -- | Generating instances for traversal on semantic information
 module Language.Haskell.Tools.AST.TH.SourceInfoTraversal where
 
diff --git a/Language/Haskell/Tools/AST/Utils/GHCInstances.hs b/Language/Haskell/Tools/AST/Utils/GHCInstances.hs
--- a/Language/Haskell/Tools/AST/Utils/GHCInstances.hs
+++ b/Language/Haskell/Tools/AST/Utils/GHCInstances.hs
@@ -1,4 +1,5 @@
-{-# LANGUAGE DeriveDataTypeable, StandaloneDeriving, TypeFamilies #-}
+{-# LANGUAGE DeriveDataTypeable, StandaloneDeriving #-}
+
 
 module Language.Haskell.Tools.AST.Utils.GHCInstances where
 
diff --git a/haskell-tools-ast.cabal b/haskell-tools-ast.cabal
--- a/haskell-tools-ast.cabal
+++ b/haskell-tools-ast.cabal
@@ -1,5 +1,5 @@
 name:                haskell-tools-ast
-version:             1.0.0.4
+version:             1.0.1.1
 synopsis:            Haskell AST for efficient tooling
 description:         A representation of a Haskell Syntax tree that contain source-related and semantic annotations. These annotations help developer tools to work with the defined program. The source information enables refactoring and program transformation tools to change the source code without losing the original format (layout, comments) of the source. Semantic information helps analyzing the program. The representation is different from the GHC's syntax tree. It contains information from all representations in GHC (different version of syntax trees, lexical and module-level information). The module is split up to put the representation of different language elements into different modules. Additionally, it contains the representation of semantic and source annotations, helper functions and generated instances for the representation of language elements. Because langauge elements may refer each other (there can be a pattern inside an expression in case of a pattern match and an expression inside a pattern if view patterns are enabled), we use hs-boot files to break up dependency cycles.
 
@@ -37,10 +37,9 @@
                      , Language.Haskell.Tools.AST.Utils.GHCInstances
 
                      , Language.Haskell.Tools.AST.Instances
-                     , Language.Haskell.Tools.AST.Instances.Eq
-                     , Language.Haskell.Tools.AST.Instances.Show
                      , Language.Haskell.Tools.AST.Instances.Data
                      , Language.Haskell.Tools.AST.Instances.Generic
+                     , Language.Haskell.Tools.AST.Instances.ClassyPlate
                      , Language.Haskell.Tools.AST.Instances.SemanticTraversal
                      , Language.Haskell.Tools.AST.Instances.SourceInfoTraversal
                      , Language.Haskell.Tools.AST.TH.SemanticTraversal
@@ -52,4 +51,6 @@
                      , uniplate         >= 1.6  && < 1.7
                      , mtl              >= 2.2  && < 2.3
                      , template-haskell >= 2.12 && < 2.13
+                     , classyplate      >= 0.3 && < 0.4
+                     , pretty      >= 1.1 && < 1.2
   default-language:    Haskell2010
