ghc-lib-parser-9.14.1.20251220: The GHC API, decoupled from GHC versions

Safe Haskell | Ignore
Language | GHC2021

GHC.HsToCore.Errors.Types

Synopsis

- newtype MinBound = MinBound Integer
- newtype MaxBound = MaxBound Integer
- type MaxUncoveredPatterns = Int
- type MaxPmCheckModels = Int
- data DsMessage
  - = DsUnknownMessage (UnknownDiagnosticFor DsMessage)
  - | DsEmptyEnumeration
  - | DsIdentitiesFound !Id !Type
  - | DsOverflowedLiterals !Integer !Name !(Maybe (MinBound, MaxBound)) !NegLiteralExtEnabled
  - | DsRedundantBangPatterns !HsMatchContextRn !SDoc
  - | DsOverlappingPatterns !HsMatchContextRn !SDoc
  - | DsInaccessibleRhs !HsMatchContextRn !SDoc
  - | DsMaxPmCheckModelsReached !MaxPmCheckModels
  - | DsNonExhaustivePatterns !HsMatchContextRn !ExhaustivityCheckType !MaxUncoveredPatterns [Id] [Nabla]
  - | DsTopLevelBindsNotAllowed !BindsType !(HsBindLR GhcTc GhcTc)
  - | DsUselessSpecialisePragma !Name !Bool !UselessSpecialisePragmaReason
  - | DsOrphanRule !CoreRule
  - | DsRuleLhsTooComplicated !CoreExpr !CoreExpr
  - | DsRuleIgnoredDueToConstructor !DataCon
  - | DsRuleBindersNotBound ![Var] ![Var] !CoreExpr !CoreExpr
  - | DsLazyPatCantBindVarsOfUnliftedType [Var]
  - | DsNotYetHandledByTH !ThRejectionReason
  - | DsAggregatedViewExpressions [[LHsExpr GhcTc]]
  - | DsUnbangedStrictPatterns !(HsBindLR GhcTc GhcTc)
  - | DsCannotMixPolyAndUnliftedBindings !(HsBindLR GhcTc GhcTc)
  - | DsWrongDoBind !(LHsExpr GhcTc) !Type
  - | DsUnusedDoBind !(LHsExpr GhcTc) !Type
  - | DsRecBindsNotAllowedForUnliftedTys ![LHsBindLR GhcTc GhcTc]
  - | DsRuleMightInlineFirst !RuleName !Var !Activation
  - | DsAnotherRuleMightFireFirst !RuleName !RuleName !Var
  - | DsIncompleteRecordSelector !Name ![ConLike] !Int
- newtype DsArgNum = DsArgNum Int
- data ThRejectionReason
  - = ThAmbiguousRecordUpdates !(HsRecUpdField GhcRn GhcRn)
  - | ThAbstractClosedTypeFamily !(LFamilyDecl GhcRn)
  - | ThForeignLabel !CLabelString
  - | ThForeignExport !(LForeignDecl GhcRn)
  - | ThMinimalPragmas
  - | ThSCCPragmas
  - | ThNoUserInline
  - | ThExoticFormOfType !(HsType GhcRn)
  - | ThAmbiguousRecordSelectors !(HsExpr GhcRn)
  - | ThMonadComprehensionSyntax !(HsExpr GhcRn)
  - | ThCostCentres !(HsExpr GhcRn)
  - | ThExpressionForm !(HsExpr GhcRn)
  - | ThExoticStatement [Stmt GhcRn (LHsExpr GhcRn)]
  - | ThExoticLiteral !(HsLit GhcRn)
  - | ThExoticPattern !(Pat GhcRn)
  - | ThGuardedLambdas !(Match GhcRn (LHsExpr GhcRn))
  - | ThNegativeOverloadedPatterns !(Pat GhcRn)
  - | ThHaddockDocumentation
  - | ThWarningAndDeprecationPragmas [LIdP GhcRn]
  - | ThSplicesWithinDeclBrackets
  - | ThNonLinearDataCon
  - | ThDataConVisibleForall
- data UselessSpecialisePragmaReason
  - = UselessSpecialiseForClassMethodSelector
  - | UselessSpecialiseForNoInlineFunction
  - | UselessSpecialiseNoSpecialisation
- uselessSpecialisePragmaKeepAnyway :: UselessSpecialisePragmaReason -> Bool
- data NegLiteralExtEnabled
  - = YesUsingNegLiterals
  - | NotUsingNegLiterals
- negLiteralExtEnabled :: DynFlags -> NegLiteralExtEnabled
- newtype ExhaustivityCheckType = ExhaustivityCheckType (Maybe WarningFlag)
- data BindsType
  - = UnliftedTypeBinds
  - | StrictBinds

# Documentation

newtype MinBound #

Constructors

MinBound Integer |

newtype MaxBound #

Constructors

MaxBound Integer |

type MaxUncoveredPatterns = Int #

type MaxPmCheckModels = Int #

data DsMessage #

Diagnostics messages emitted during desugaring.

Constructors

DsUnknownMessage (UnknownDiagnosticFor DsMessage) | Simply wraps a generic `Diagnostic` message.
DsEmptyEnumeration | DsEmptyEnumeration is a warning (controlled by the -Wempty-enumerations flag) that is emitted if an enumeration is empty. Example(s): main :: IO () main = do let enum = [5 .. 3] print enum Here `enum` would yield an empty list, because 5 is greater than 3. Test case(s): warningsshould_compileT10930 warningsshould_compileT18402 warningsshould_compileT10930b numericshould_compileT10929 numericshould_compileT7881 deSugarshould_runT18172
DsIdentitiesFound !Id !Type | DsIdentitiesFound is a warning (controlled by the -Widentities flag) that is emitted on uses of Prelude numeric conversions that are probably the identity (and hence could be omitted). Example(s): main :: IO () main = do let x = 10 print $ conv 10 where conv :: Int -> Int conv x = fromIntegral x Here calling `conv` is essentially the identity function, and therefore can be omitted. Test case(s): deSugarshould_compileT4488
DsOverflowedLiterals !Integer !Name !(Maybe (MinBound, MaxBound)) !NegLiteralExtEnabled |
DsRedundantBangPatterns !HsMatchContextRn !SDoc |
DsOverlappingPatterns !HsMatchContextRn !SDoc |
DsInaccessibleRhs !HsMatchContextRn !SDoc |
DsMaxPmCheckModelsReached !MaxPmCheckModels |
DsNonExhaustivePatterns !HsMatchContextRn !ExhaustivityCheckType !MaxUncoveredPatterns [Id] [Nabla] |
DsTopLevelBindsNotAllowed !BindsType !(HsBindLR GhcTc GhcTc) |
DsUselessSpecialisePragma | DsUselessSpecialisePragma is a warning (controlled by the -Wuseless-specialisations flag) that is emitted for SPECIALISE pragmas that (most likely) don't do anything. Examples: foo :: forall a. a -> a {-# SPECIALISE foo :: Int -> Int #-}
Fields !Name !Bool is this a `SPECIALISE instance` pragma? !UselessSpecialisePragmaReason
DsOrphanRule !CoreRule |
DsRuleLhsTooComplicated !CoreExpr !CoreExpr |
DsRuleIgnoredDueToConstructor !DataCon |
DsRuleBindersNotBound |
Fields ![Var] The list of unbound binders ![Var] The original binders !CoreExpr The original LHS !CoreExpr The optimised LHS
DsLazyPatCantBindVarsOfUnliftedType [Var] |
DsNotYetHandledByTH !ThRejectionReason |
DsAggregatedViewExpressions [[LHsExpr GhcTc]] |
DsUnbangedStrictPatterns !(HsBindLR GhcTc GhcTc) |
DsCannotMixPolyAndUnliftedBindings !(HsBindLR GhcTc GhcTc) |
DsWrongDoBind !(LHsExpr GhcTc) !Type |
DsUnusedDoBind !(LHsExpr GhcTc) !Type |
DsRecBindsNotAllowedForUnliftedTys ![LHsBindLR GhcTc GhcTc] |
DsRuleMightInlineFirst !RuleName !Var !Activation |
DsAnotherRuleMightFireFirst !RuleName !RuleName !Var |
DsIncompleteRecordSelector | DsIncompleteRecordSelector is a warning triggered when we are not certain whether a record selector application will be successful. Currently, this means that the warning is triggered when there is a record selector of a data type that does not have that field in all its constructors. Example(s): data T = T1 | T2 {x :: Bool} f :: T -> Bool f a = x a Test cases: DsIncompleteRecSel1 DsIncompleteRecSel2 DsIncompleteRecSel3
Fields !Name The selector ![ConLike] The partial constructors !Int The max number of constructors reported

#### Instances

Instances details

Generic DsMessage # |
Instance details Defined in GHC.HsToCore.Errors.Types Associated Types
type Rep DsMessage |
Instance details Defined in GHC.HsToCore.Errors.Types type Rep DsMessage = D1 ('MetaData "DsMessage" "GHC.HsToCore.Errors.Types" "ghc-lib-parser-9.14.1.20251220-PtFrlL5ZJN3Qo3Axa3c6X" 'False) ((((C1 ('MetaCons "DsUnknownMessage" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (UnknownDiagnosticFor DsMessage))) :+: (C1 ('MetaCons "DsEmptyEnumeration" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "DsIdentitiesFound" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Id) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Type)))) :+: (C1 ('MetaCons "DsOverflowedLiterals" 'PrefixI 'False) ((S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Integer) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Name)) :*: (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (Maybe (MinBound, MaxBound))) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 NegLiteralExtEnabled))) :+: (C1 ('MetaCons "DsRedundantBangPatterns" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 HsMatchContextRn) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 SDoc)) :+: C1 ('MetaCons "DsOverlappingPatterns" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 HsMatchContextRn) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 SDoc))))) :+: ((C1 ('MetaCons "DsInaccessibleRhs" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 HsMatchContextRn) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 SDoc)) :+: (C1 ('MetaCons "DsMaxPmCheckModelsReached" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 MaxPmCheckModels)) :+: C1 ('MetaCons "DsNonExhaustivePatterns" 'PrefixI 'False) ((S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 HsMatchContextRn) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 ExhaustivityCheckType)) :*: (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 MaxUncoveredPatterns) :*: (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [Id]) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [Nabla])))))) :+: ((C1 ('MetaCons "DsTopLevelBindsNotAllowed" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 BindsType) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (HsBindLR GhcTc GhcTc))) :+: C1 ('MetaCons "DsUselessSpecialisePragma" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Name) :*: (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Bool) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 UselessSpecialisePragmaReason)))) :+: (C1 ('MetaCons "DsOrphanRule" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 CoreRule)) :+: C1 ('MetaCons "DsRuleLhsTooComplicated" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 CoreExpr) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 CoreExpr)))))) :+: (((C1 ('MetaCons "DsRuleIgnoredDueToConstructor" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 DataCon)) :+: (C1 ('MetaCons "DsRuleBindersNotBound" 'PrefixI 'False) ((S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 [Var]) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 [Var])) :*: (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 CoreExpr) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 CoreExpr))) :+: C1 ('MetaCons "DsLazyPatCantBindVarsOfUnliftedType" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [Var])))) :+: (C1 ('MetaCons "DsNotYetHandledByTH" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 ThRejectionReason)) :+: (C1 ('MetaCons "DsAggregatedViewExpressions" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [[LHsExpr GhcTc]])) :+: C1 ('MetaCons "DsUnbangedStrictPatterns" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (HsBindLR GhcTc GhcTc)))))) :+: ((C1 ('MetaCons "DsCannotMixPolyAndUnliftedBindings" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (HsBindLR GhcTc GhcTc))) :+: (C1 ('MetaCons "DsWrongDoBind" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (LHsExpr GhcTc)) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Type)) :+: C1 ('MetaCons "DsUnusedDoBind" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (LHsExpr GhcTc)) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Type)))) :+: ((C1 ('MetaCons "DsRecBindsNotAllowedForUnliftedTys" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 [LHsBindLR GhcTc GhcTc])) :+: C1 ('MetaCons "DsRuleMightInlineFirst" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 RuleName) :*: (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Var) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Activation)))) :+: (C1 ('MetaCons "DsAnotherRuleMightFireFirst" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 RuleName) :*: (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 RuleName) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Var))) :+: C1 ('MetaCons "DsIncompleteRecordSelector" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Name) :*: (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 [ConLike]) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Int))))))))
Methods from :: DsMessage -> Rep DsMessage x # to :: Rep DsMessage x -> DsMessage #
Diagnostic DsMessage # |
Instance details Defined in GHC.HsToCore.Errors.Ppr Associated Types
type DiagnosticOpts DsMessage |
Instance details Defined in GHC.HsToCore.Errors.Ppr type DiagnosticOpts DsMessage = NoDiagnosticOpts
type DiagnosticHint DsMessage |
Instance details Defined in GHC.HsToCore.Errors.Ppr type DiagnosticHint DsMessage = GhcHint
Methods diagnosticMessage :: DiagnosticOpts DsMessage -> DsMessage -> DecoratedSDoc # diagnosticReason :: DsMessage -> DiagnosticReason # diagnosticHints :: DsMessage -> [DiagnosticHint DsMessage] # diagnosticCode :: DsMessage -> Maybe DiagnosticCode #
type Rep DsMessage # |
Instance details Defined in GHC.HsToCore.Errors.Types type Rep DsMessage = D1 ('MetaData "DsMessage" "GHC.HsToCore.Errors.Types" "ghc-lib-parser-9.14.1.20251220-PtFrlL5ZJN3Qo3Axa3c6X" 'False) ((((C1 ('MetaCons "DsUnknownMessage" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (UnknownDiagnosticFor DsMessage))) :+: (C1 ('MetaCons "DsEmptyEnumeration" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "DsIdentitiesFound" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Id) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Type)))) :+: (C1 ('MetaCons "DsOverflowedLiterals" 'PrefixI 'False) ((S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Integer) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Name)) :*: (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (Maybe (MinBound, MaxBound))) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 NegLiteralExtEnabled))) :+: (C1 ('MetaCons "DsRedundantBangPatterns" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 HsMatchContextRn) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 SDoc)) :+: C1 ('MetaCons "DsOverlappingPatterns" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 HsMatchContextRn) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 SDoc))))) :+: ((C1 ('MetaCons "DsInaccessibleRhs" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 HsMatchContextRn) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 SDoc)) :+: (C1 ('MetaCons "DsMaxPmCheckModelsReached" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 MaxPmCheckModels)) :+: C1 ('MetaCons "DsNonExhaustivePatterns" 'PrefixI 'False) ((S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 HsMatchContextRn) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 ExhaustivityCheckType)) :*: (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 MaxUncoveredPatterns) :*: (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [Id]) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [Nabla])))))) :+: ((C1 ('MetaCons "DsTopLevelBindsNotAllowed" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 BindsType) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (HsBindLR GhcTc GhcTc))) :+: C1 ('MetaCons "DsUselessSpecialisePragma" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Name) :*: (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Bool) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 UselessSpecialisePragmaReason)))) :+: (C1 ('MetaCons "DsOrphanRule" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 CoreRule)) :+: C1 ('MetaCons "DsRuleLhsTooComplicated" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 CoreExpr) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 CoreExpr)))))) :+: (((C1 ('MetaCons "DsRuleIgnoredDueToConstructor" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 DataCon)) :+: (C1 ('MetaCons "DsRuleBindersNotBound" 'PrefixI 'False) ((S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 [Var]) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 [Var])) :*: (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 CoreExpr) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 CoreExpr))) :+: C1 ('MetaCons "DsLazyPatCantBindVarsOfUnliftedType" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [Var])))) :+: (C1 ('MetaCons "DsNotYetHandledByTH" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 ThRejectionReason)) :+: (C1 ('MetaCons "DsAggregatedViewExpressions" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [[LHsExpr GhcTc]])) :+: C1 ('MetaCons "DsUnbangedStrictPatterns" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (HsBindLR GhcTc GhcTc)))))) :+: ((C1 ('MetaCons "DsCannotMixPolyAndUnliftedBindings" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (HsBindLR GhcTc GhcTc))) :+: (C1 ('MetaCons "DsWrongDoBind" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (LHsExpr GhcTc)) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Type)) :+: C1 ('MetaCons "DsUnusedDoBind" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (LHsExpr GhcTc)) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Type)))) :+: ((C1 ('MetaCons "DsRecBindsNotAllowedForUnliftedTys" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 [LHsBindLR GhcTc GhcTc])) :+: C1 ('MetaCons "DsRuleMightInlineFirst" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 RuleName) :*: (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Var) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Activation)))) :+: (C1 ('MetaCons "DsAnotherRuleMightFireFirst" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 RuleName) :*: (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 RuleName) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Var))) :+: C1 ('MetaCons "DsIncompleteRecordSelector" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Name) :*: (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 [ConLike]) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Int))))))))
type DiagnosticHint DsMessage # |
Instance details Defined in GHC.HsToCore.Errors.Ppr type DiagnosticHint DsMessage = GhcHint
type DiagnosticOpts DsMessage # |
Instance details Defined in GHC.HsToCore.Errors.Ppr type DiagnosticOpts DsMessage = NoDiagnosticOpts

newtype DsArgNum #

Constructors

DsArgNum Int |

data ThRejectionReason #

Why TemplateHaskell rejected the splice. Used in the `DsNotYetHandledByTH` constructor of a `DsMessage`.

Constructors

ThAmbiguousRecordUpdates !(HsRecUpdField GhcRn GhcRn) |
ThAbstractClosedTypeFamily !(LFamilyDecl GhcRn) |
ThForeignLabel !CLabelString |
ThForeignExport !(LForeignDecl GhcRn) |
ThMinimalPragmas |
ThSCCPragmas |
ThNoUserInline |
ThExoticFormOfType !(HsType GhcRn) |
ThAmbiguousRecordSelectors !(HsExpr GhcRn) |
ThMonadComprehensionSyntax !(HsExpr GhcRn) |
ThCostCentres !(HsExpr GhcRn) |
ThExpressionForm !(HsExpr GhcRn) |
ThExoticStatement [Stmt GhcRn (LHsExpr GhcRn)] |
ThExoticLiteral !(HsLit GhcRn) |
ThExoticPattern !(Pat GhcRn) |
ThGuardedLambdas !(Match GhcRn (LHsExpr GhcRn)) |
ThNegativeOverloadedPatterns !(Pat GhcRn) |
ThHaddockDocumentation |
ThWarningAndDeprecationPragmas [LIdP GhcRn] |
ThSplicesWithinDeclBrackets |
ThNonLinearDataCon |
ThDataConVisibleForall |

data UselessSpecialisePragmaReason #

Why is a `SPECIALISE` pragmas useless?

Constructors

UselessSpecialiseForClassMethodSelector | Useless `SPECIALISE` pragma for a class method
UselessSpecialiseForNoInlineFunction | Useless `SPECIALISE` pragma for a function with NOINLINE
UselessSpecialiseNoSpecialisation | Useless `SPECIALISE` pragma which generates a specialised function which is identical to the original function at runtime.

#### Instances

Instances details

Generic UselessSpecialisePragmaReason # |
Instance details Defined in GHC.HsToCore.Errors.Types Associated Types
type Rep UselessSpecialisePragmaReason |
Instance details Defined in GHC.HsToCore.Errors.Types type Rep UselessSpecialisePragmaReason = D1 ('MetaData "UselessSpecialisePragmaReason" "GHC.HsToCore.Errors.Types" "ghc-lib-parser-9.14.1.20251220-PtFrlL5ZJN3Qo3Axa3c6X" 'False) (C1 ('MetaCons "UselessSpecialiseForClassMethodSelector" 'PrefixI 'False) (U1 :: Type -> Type) :+: (C1 ('MetaCons "UselessSpecialiseForNoInlineFunction" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "UselessSpecialiseNoSpecialisation" 'PrefixI 'False) (U1 :: Type -> Type)))
Methods from :: UselessSpecialisePragmaReason -> Rep UselessSpecialisePragmaReason x # to :: Rep UselessSpecialisePragmaReason x -> UselessSpecialisePragmaReason #
type Rep UselessSpecialisePragmaReason # |
Instance details Defined in GHC.HsToCore.Errors.Types type Rep UselessSpecialisePragmaReason = D1 ('MetaData "UselessSpecialisePragmaReason" "GHC.HsToCore.Errors.Types" "ghc-lib-parser-9.14.1.20251220-PtFrlL5ZJN3Qo3Axa3c6X" 'False) (C1 ('MetaCons "UselessSpecialiseForClassMethodSelector" 'PrefixI 'False) (U1 :: Type -> Type) :+: (C1 ('MetaCons "UselessSpecialiseForNoInlineFunction" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "UselessSpecialiseNoSpecialisation" 'PrefixI 'False) (U1 :: Type -> Type)))

uselessSpecialisePragmaKeepAnyway :: UselessSpecialisePragmaReason -> Bool #

data NegLiteralExtEnabled #

Constructors

YesUsingNegLiterals |
NotUsingNegLiterals |

negLiteralExtEnabled :: DynFlags -> NegLiteralExtEnabled #

newtype ExhaustivityCheckType #

Constructors

ExhaustivityCheckType (Maybe WarningFlag) |

data BindsType #

Constructors

UnliftedTypeBinds |
StrictBinds |