plutus-core-1.0.0.1: Language library for Plutus Core
Safe HaskellNone
LanguageHaskell2010

ErrorCode

Synopsis

Documentation

class HasErrorCode a where Source #

Assigns an error-code to data-constructors (values) of error types. Note, when implementing this method you're only supposed to look at the outermost constructor (whnf) of the a value to decide for the error-code.

Methods

errorCode :: a -> ErrorCode Source #

Instances

Instances details
HasErrorCode FreeVariableError Source # 
Instance details

Defined in PlutusCore.DeBruijn.Internal

HasErrorCode UnliftingError Source # 
Instance details

Defined in PlutusCore.Evaluation.Machine.Exception

HasErrorCode ParseError Source # 
Instance details

Defined in PlutusCore.Error

HasErrorCode CekUserError Source # 
Instance details

Defined in UntypedPlutusCore.Evaluation.Machine.Cek.Internal

HasErrorCode (MachineError err) Source # 
Instance details

Defined in PlutusCore.Evaluation.Machine.Exception

HasErrorCode (UniqueError _a) Source # 
Instance details

Defined in PlutusCore.Error

(HasErrorCode user, HasErrorCode internal) => HasErrorCode (EvaluationError user internal) Source # 
Instance details

Defined in PlutusCore.Evaluation.Machine.Exception

Methods

errorCode :: EvaluationError user internal -> ErrorCode Source #

HasErrorCode err => HasErrorCode (ErrorWithCause err t) Source # 
Instance details

Defined in PlutusCore.Evaluation.Machine.Exception

HasErrorCode (TypeErrorExt _a _b) Source # 
Instance details

Defined in PlutusIR.Error

HasErrorCode (Error _a _b _c) Source # 
Instance details

Defined in PlutusCore.Error

Methods

errorCode :: Error _a _b _c -> ErrorCode Source #

HasErrorCode (Error _a _b _c) Source # 
Instance details

Defined in PlutusIR.Error

Methods

errorCode :: Error _a _b _c -> ErrorCode Source #

HasErrorCode (TypeError _a _b _c _d) Source # 
Instance details

Defined in PlutusCore.Error

Methods

errorCode :: TypeError _a _b _c _d -> ErrorCode Source #

HasErrorCode (NormCheckError _a _b _c _d _e) Source # 
Instance details

Defined in PlutusCore.Error

Methods

errorCode :: NormCheckError _a _b _c _d _e -> ErrorCode Source #

newtype ErrorCode Source #

A wrapper to Natural so as to override the pretty instance of Natural with zero padding

Constructors

ErrorCode Natural