plutus-core-1.70.0.0: Language library for Plutus Core
Safe HaskellSafe-Inferred
LanguageHaskell2010

PlutusIR.Error

Documentation

data Error uni fun a Source #

Constructors

CompilationError !a !Text

A generic compilation error.

UnsupportedError !a !Text

An error relating specifically to an unsupported feature.

OptionsError !Text

An error relating to compilation options.

PLCError !(Error uni fun a)

An error from running some PLC function, lifted into this error type for convenience.

PLCTypeError !(TypeError (Term TyName Name uni fun ()) uni fun a) 
PIRTypeError !(TypeErrorExt uni a) 

Instances

Instances details
(PrettyUni uni, Pretty fun, Pretty ann) ⇒ PrettyBy PrettyConfigPlc (Error uni fun ann) Source # 
Instance details

Defined in PlutusIR.Error

Methods

prettyBy ∷ PrettyConfigPlc → Error uni fun ann → Doc ann0 Source #

prettyListBy ∷ PrettyConfigPlc → [Error uni fun ann] → Doc ann0 Source #

Functor (Error uni fun) Source # 
Instance details

Defined in PlutusIR.Error

Methods

fmap ∷ (a → b) → Error uni fun a → Error uni fun b Source #

(<$) ∷ a → Error uni fun b → Error uni fun a Source #

(ThrowableBuiltins uni fun, Pretty ann, Typeable ann) ⇒ Exception (Error uni fun ann) Source # 
Instance details

Defined in PlutusIR.Error

Methods

toException ∷ Error uni fun ann → SomeException Source #

fromException ∷ SomeException → Maybe (Error uni fun ann) Source #

displayException ∷ Error uni fun ann → String Source #

(PrettyUni uni, Pretty fun, Pretty ann) ⇒ Show (Error uni fun ann) Source # 
Instance details

Defined in PlutusIR.Error

Methods

showsPrec ∷ Int → Error uni fun ann → ShowS Source #

show ∷ Error uni fun ann → String Source #

showList ∷ [Error uni fun ann] → ShowS Source #

(PrettyUni uni, Pretty fun, Pretty ann) ⇒ Pretty (Error uni fun ann) Source # 
Instance details

Defined in PlutusIR.Error

Methods

pretty ∷ Error uni fun ann → Doc ann0 Source #

prettyList ∷ [Error uni fun ann] → Doc ann0 Source #

data TypeError term (uni ∷ Type → Type) fun ann Source #

Instances

Instances details
(Pretty term, PrettyUni uni, Pretty fun, Pretty ann) ⇒ PrettyBy PrettyConfigPlc (TypeError term uni fun ann) 
Instance details

Defined in PlutusCore.Error

Methods

prettyBy ∷ PrettyConfigPlc → TypeError term uni fun ann → Doc ann0 Source #

prettyListBy ∷ PrettyConfigPlc → [TypeError term uni fun ann] → Doc ann0 Source #

Functor (TypeError term uni fun) 
Instance details

Defined in PlutusCore.Error

Methods

fmap ∷ (a → b) → TypeError term uni fun a → TypeError term uni fun b Source #

(<$) ∷ a → TypeError term uni fun b → TypeError term uni fun a Source #

Generic (TypeError term uni fun ann) 
Instance details

Defined in PlutusCore.Error

Associated Types

type Rep (TypeError term uni fun ann) ∷ Type → Type Source #

Methods

from ∷ TypeError term uni fun ann → Rep (TypeError term uni fun ann) x Source #

to ∷ Rep (TypeError term uni fun ann) x → TypeError term uni fun ann Source #

(GShow uni, Show term, Show fun, Show ann) ⇒ Show (TypeError term uni fun ann) 
Instance details

Defined in PlutusCore.Error

Methods

showsPrec ∷ Int → TypeError term uni fun ann → ShowS Source #

show ∷ TypeError term uni fun ann → String Source #

showList ∷ [TypeError term uni fun ann] → ShowS Source #

(Closed uni, NFData ann, NFData term, NFData fun) ⇒ NFData (TypeError term uni fun ann) 
Instance details

Defined in PlutusCore.Error

Methods

rnf ∷ TypeError term uni fun ann → () Source #

(GEq uni, Eq term, Eq fun, Eq ann) ⇒ Eq (TypeError term uni fun ann) 
Instance details

Defined in PlutusCore.Error

Methods

(==) ∷ TypeError term uni fun ann → TypeError term uni fun ann → Bool Source #

(/=) ∷ TypeError term uni fun ann → TypeError term uni fun ann → Bool Source #

type Rep (TypeError term uni fun ann) 
Instance details

Defined in PlutusCore.Error

type Rep (TypeError term uni fun ann) = D1 ('MetaData "TypeError" "PlutusCore.Error" "plutus-core-1.70.0.0-inplace" 'False) (((C1 ('MetaCons "KindMismatch" 'PrefixI 'False) ((S1 ('MetaSel ('Nothing ∷ Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 ann) :*: S1 ('MetaSel ('Nothing ∷ Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (Type TyName uni ()))) :*: (S1 ('MetaSel ('Nothing ∷ Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (ExpectedShapeOr (Kind ()))) :*: S1 ('MetaSel ('Nothing ∷ Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (Kind ())))) :+: C1 ('MetaCons "TypeMismatch" 'PrefixI 'False) ((S1 ('MetaSel ('Nothing ∷ Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 ann) :*: S1 ('MetaSel ('Nothing ∷ Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 term)) :*: (S1 ('MetaSel ('Nothing ∷ Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (ExpectedShapeOr (Type TyName uni ()))) :*: S1 ('MetaSel ('Nothing ∷ Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (Normalized (Type TyName uni ())))))) :+: (C1 ('MetaCons "TyNameMismatch" 'PrefixI 'False) (S1 ('MetaSel ('Nothing ∷ Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 ann) :*: (S1 ('MetaSel ('Nothing ∷ Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 TyName) :*: S1 ('MetaSel ('Nothing ∷ Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 TyName))) :+: C1 ('MetaCons "NameMismatch" 'PrefixI 'False) (S1 ('MetaSel ('Nothing ∷ Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 ann) :*: (S1 ('MetaSel ('Nothing ∷ Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Name) :*: S1 ('MetaSel ('Nothing ∷ Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Name))))) :+: ((C1 ('MetaCons "FreeTypeVariableE" 'PrefixI 'False) (S1 ('MetaSel ('Nothing ∷ Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 ann) :*: S1 ('MetaSel ('Nothing ∷ Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 TyName)) :+: C1 ('MetaCons "FreeVariableE" 'PrefixI 'False) (S1 ('MetaSel ('Nothing ∷ Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 ann) :*: S1 ('MetaSel ('Nothing ∷ Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Name))) :+: (C1 ('MetaCons "UnknownBuiltinFunctionE" 'PrefixI 'False) (S1 ('MetaSel ('Nothing ∷ Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 ann) :*: S1 ('MetaSel ('Nothing ∷ Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 fun)) :+: C1 ('MetaCons "UnsupportedCaseBuiltin" 'PrefixI 'False) (S1 ('MetaSel ('Nothing ∷ Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 ann) :*: S1 ('MetaSel ('Nothing ∷ Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Text)))))

data TypeErrorExt uni ann Source #

Constructors

MalformedDataConstrResType !ann !(Type TyName uni ann) 

Instances

Instances details
(PrettyUni uni, Pretty ann) ⇒ PrettyBy PrettyConfigPlc (TypeErrorExt uni ann) Source # 
Instance details

Defined in PlutusIR.Error

Methods

prettyBy ∷ PrettyConfigPlc → TypeErrorExt uni ann → Doc ann0 Source #

prettyListBy ∷ PrettyConfigPlc → [TypeErrorExt uni ann] → Doc ann0 Source #

Functor (TypeErrorExt uni) Source # 
Instance details

Defined in PlutusIR.Error

Methods

fmap ∷ (a → b) → TypeErrorExt uni a → TypeErrorExt uni b Source #

(<$) ∷ a → TypeErrorExt uni b → TypeErrorExt uni a Source #

Generic (TypeErrorExt uni ann) Source # 
Instance details

Defined in PlutusIR.Error

Associated Types

type Rep (TypeErrorExt uni ann) ∷ Type → Type Source #

Methods

from ∷ TypeErrorExt uni ann → Rep (TypeErrorExt uni ann) x Source #

to ∷ Rep (TypeErrorExt uni ann) x → TypeErrorExt uni ann Source #

(Show ann, GShow uni) ⇒ Show (TypeErrorExt uni ann) Source # 
Instance details

Defined in PlutusIR.Error

Methods

showsPrec ∷ Int → TypeErrorExt uni ann → ShowS Source #

show ∷ TypeErrorExt uni ann → String Source #

showList ∷ [TypeErrorExt uni ann] → ShowS Source #

(NFData ann, Closed uni) ⇒ NFData (TypeErrorExt uni ann) Source # 
Instance details

Defined in PlutusIR.Error

Methods

rnf ∷ TypeErrorExt uni ann → () Source #

(Eq ann, GEq uni) ⇒ Eq (TypeErrorExt uni ann) Source # 
Instance details

Defined in PlutusIR.Error

Methods

(==) ∷ TypeErrorExt uni ann → TypeErrorExt uni ann → Bool Source #

(/=) ∷ TypeErrorExt uni ann → TypeErrorExt uni ann → Bool Source #

type Rep (TypeErrorExt uni ann) Source # 
Instance details

Defined in PlutusIR.Error

type Rep (TypeErrorExt uni ann) = D1 ('MetaData "TypeErrorExt" "PlutusIR.Error" "plutus-core-1.70.0.0-inplace-plutus-ir" 'False) (C1 ('MetaCons "MalformedDataConstrResType" 'PrefixI 'False) (S1 ('MetaSel ('Nothing ∷ Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 ann) :*: S1 ('MetaSel ('Nothing ∷ Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (Type TyName uni ann))))

newtype Normalized a Source #

Constructors

Normalized 

Fields

Instances

Instances details
Foldable Normalized 
Instance details

Defined in PlutusCore.Core.Type

Methods

fold ∷ Monoid m ⇒ Normalized m → m Source #

foldMap ∷ Monoid m ⇒ (a → m) → Normalized a → m Source #

foldMap' ∷ Monoid m ⇒ (a → m) → Normalized a → m Source #

foldr ∷ (a → b → b) → b → Normalized a → b Source #

foldr' ∷ (a → b → b) → b → Normalized a → b Source #

foldl ∷ (b → a → b) → b → Normalized a → b Source #

foldl' ∷ (b → a → b) → b → Normalized a → b Source #

foldr1 ∷ (a → a → a) → Normalized a → a Source #

foldl1 ∷ (a → a → a) → Normalized a → a Source #

toList ∷ Normalized a → [a] Source #

null ∷ Normalized a → Bool Source #

length ∷ Normalized a → Int Source #

elem ∷ Eq a ⇒ a → Normalized a → Bool Source #

maximum ∷ Ord a ⇒ Normalized a → a Source #

minimum ∷ Ord a ⇒ Normalized a → a Source #

sum ∷ Num a ⇒ Normalized a → a Source #

product ∷ Num a ⇒ Normalized a → a Source #

Traversable Normalized 
Instance details

Defined in PlutusCore.Core.Type

Methods

traverse ∷ Applicative f ⇒ (a → f b) → Normalized a → f (Normalized b) Source #

sequenceA ∷ Applicative f ⇒ Normalized (f a) → f (Normalized a) Source #

mapM ∷ Monad m ⇒ (a → m b) → Normalized a → m (Normalized b) Source #

sequence ∷ Monad m ⇒ Normalized (m a) → m (Normalized a) Source #

Applicative Normalized 
Instance details

Defined in PlutusCore.Core.Type

Methods

pure ∷ a → Normalized a Source #

(<*>) ∷ Normalized (a → b) → Normalized a → Normalized b Source #

liftA2 ∷ (a → b → c) → Normalized a → Normalized b → Normalized c Source #

(*>) ∷ Normalized a → Normalized b → Normalized b Source #

(<*) ∷ Normalized a → Normalized b → Normalized a Source #

Functor Normalized 
Instance details

Defined in PlutusCore.Core.Type

Methods

fmap ∷ (a → b) → Normalized a → Normalized b Source #

(<$) ∷ a → Normalized b → Normalized a Source #

PrettyBy config a ⇒ PrettyBy config (Normalized a) 
Instance details

Defined in PlutusCore.Core.Type

Methods

prettyBy ∷ config → Normalized a → Doc ann Source #

prettyListBy ∷ config → [Normalized a] → Doc ann Source #

Generic (Normalized a) 
Instance details

Defined in PlutusCore.Core.Type

Associated Types

type Rep (Normalized a) ∷ Type → Type Source #

Methods

from ∷ Normalized a → Rep (Normalized a) x Source #

to ∷ Rep (Normalized a) x → Normalized a Source #

Show a ⇒ Show (Normalized a) 
Instance details

Defined in PlutusCore.Core.Type

NFData a ⇒ NFData (Normalized a) 
Instance details

Defined in PlutusCore.Core.Type

Methods

rnf ∷ Normalized a → () Source #

Eq a ⇒ Eq (Normalized a) 
Instance details

Defined in PlutusCore.Core.Type

Methods

(==) ∷ Normalized a → Normalized a → Bool Source #

(/=) ∷ Normalized a → Normalized a → Bool Source #

Rename a ⇒ Rename (Normalized a) 
Instance details

Defined in PlutusCore.Rename

Methods

rename ∷ MonadQuote m ⇒ Normalized a → m (Normalized a) Source #

Pretty a ⇒ Pretty (Normalized a) 
Instance details

Defined in PlutusCore.Core.Type

Methods

pretty ∷ Normalized a → Doc ann Source #

prettyList ∷ [Normalized a] → Doc ann Source #

type Rep (Normalized a) 
Instance details

Defined in PlutusCore.Core.Type

type Rep (Normalized a) = D1 ('MetaData "Normalized" "PlutusCore.Core.Type" "plutus-core-1.70.0.0-inplace" 'True) (C1 ('MetaCons "Normalized" 'PrefixI 'True) (S1 ('MetaSel ('Just "unNormalized") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 a)))