plutus-core-1.0.0.1: Language library for Plutus Core
Safe Haskell None
Language Haskell2010

PlutusCore

Synopsis

Parser

parseProgram :: ByteString -> Either ( ParseErrorBundle Text ParseError ) ( Program TyName Name DefaultUni DefaultFun SourcePos ) Source #

Parse a PLC program. The resulting program will have fresh names. The underlying monad must be capable of handling any parse errors.

parseTerm :: ByteString -> Either ( ParseErrorBundle Text ParseError ) ( Term TyName Name DefaultUni DefaultFun SourcePos ) Source #

Parse a PLC term. The resulting program will have fresh names. The underlying monad must be capable of handling any parse errors.

parseType :: ByteString -> Either ( ParseErrorBundle Text ParseError ) ( Type TyName DefaultUni SourcePos ) Source #

Parse a PLC type. The resulting program will have fresh names. The underlying monad must be capable of handling any parse errors.

parseScoped :: MonadQuote f => ByteString -> f ( Program TyName Name DefaultUni DefaultFun SourcePos ) Source #

Parse and rewrite so that names are globally unique, not just unique within their scope. don't require there to be no free variables at this point, we might be parsing an open term

Builtins

data Some (tag :: k -> Type ) where Source #

Existential. This is type is useful to hide GADTs' parameters.

>>> data Tag :: * -> * where TagInt :: Tag Int; TagBool :: Tag Bool
>>> instance GShow Tag where gshowsPrec _ TagInt = showString "TagInt"; gshowsPrec _ TagBool = showString "TagBool"
>>> classify s = case s of "TagInt" -> [mkGReadResult TagInt]; "TagBool" -> [mkGReadResult TagBool]; _ -> []
>>> instance GRead Tag where greadsPrec _ s = [ (r, rest) | (con, rest) <-  lex s, r <- classify con ]

You can either use PatternSynonyms (available with GHC >= 8.0)

>>> let x = Some TagInt
>>> x
Some TagInt
>>> case x of { Some TagInt -> "I"; Some TagBool -> "B" } :: String
"I"

or you can use functions

>>> let y = mkSome TagBool
>>> y
Some TagBool
>>> withSome y $ \y' -> case y' of { TagInt -> "I"; TagBool -> "B" } :: String
"B"

The implementation of mapSome is safe .

>>> let f :: Tag a -> Tag a; f TagInt = TagInt; f TagBool = TagBool
>>> mapSome f y
Some TagBool

but you can also use:

>>> withSome y (mkSome . f)
Some TagBool
>>> read "Some TagBool" :: Some Tag
Some TagBool
>>> read "mkSome TagInt" :: Some Tag
Some TagInt

Bundled Patterns

pattern Some :: forall k tag (a :: k). () => tag a -> Some tag

Instances

Instances details
GEq tag => Eq ( Some tag)
Instance details

Defined in Data.Some.Newtype

GCompare tag => Ord ( Some tag)
Instance details

Defined in Data.Some.Newtype

GRead f => Read ( Some f)
Instance details

Defined in Data.Some.Newtype

GShow tag => Show ( Some tag)
Instance details

Defined in Data.Some.Newtype

Applicative m => Semigroup ( Some m)
Instance details

Defined in Data.Some.Newtype

Applicative m => Monoid ( Some m)
Instance details

Defined in Data.Some.Newtype

GNFData tag => NFData ( Some tag)
Instance details

Defined in Data.Some.Newtype

Methods

rnf :: Some tag -> () Source #

( Closed uni, Everywhere uni Flat ) => Flat ( Some ( ValueOf uni)) Source #
Instance details

Defined in PlutusCore.Flat

( Closed uni, Everywhere uni PrettyConst ) => Pretty ( Some ( ValueOf uni)) Source #
Instance details

Defined in PlutusCore.Pretty.PrettyConst

( Closed uni, Everywhere uni ExMemoryUsage ) => ExMemoryUsage ( Some ( ValueOf uni)) Source #
Instance details

Defined in PlutusCore.Evaluation.Machine.ExMemory

data SomeTypeIn uni Source #

A particular type from a universe.

Constructors

forall k (a :: k). SomeTypeIn !(uni ( Esc a))

Instances

Instances details
GEq uni => Eq ( SomeTypeIn uni) Source #
Instance details

Defined in Universe.Core

GCompare uni => Ord ( SomeTypeIn uni) Source #
Instance details

Defined in Universe.Core

GShow uni => Show ( SomeTypeIn uni) Source #
Instance details

Defined in Universe.Core

Closed uni => NFData ( SomeTypeIn uni) Source #
Instance details

Defined in Universe.Core

Closed uni => Flat ( SomeTypeIn uni) Source #
Instance details

Defined in PlutusCore.Flat

GShow uni => Pretty ( SomeTypeIn uni) Source #
Instance details

Defined in PlutusCore.Pretty.PrettyConst

ExMemoryUsage ( SomeTypeIn uni) Source #
Instance details

Defined in PlutusCore.Evaluation.Machine.ExMemory

data Kinded uni ta where Source #

Constructors

Kinded :: Typeable k => !(uni ( Esc a)) -> Kinded uni ( Esc (a :: k))

Instances

Instances details
GShow uni => GShow ( Kinded uni :: Type -> Type ) Source #
Instance details

Defined in Universe.Core

Methods

gshowsPrec :: forall (a :: k). Int -> Kinded uni a -> ShowS Source #

GShow uni => Show ( Kinded uni ta) Source #
Instance details

Defined in Universe.Core

data ValueOf uni a Source #

A value of a particular type from a universe.

Constructors

ValueOf !(uni ( Esc a)) !a

Instances

Instances details
( GShow uni, Closed uni, Everywhere uni Show ) => GShow ( ValueOf uni :: Type -> Type ) Source #
Instance details

Defined in Universe.Core

Methods

gshowsPrec :: forall (a :: k). Int -> ValueOf uni a -> ShowS Source #

( GEq uni, Closed uni, Everywhere uni Eq ) => GEq ( ValueOf uni :: Type -> Type ) Source #
Instance details

Defined in Universe.Core

Methods

geq :: forall (a :: k) (b :: k). ValueOf uni a -> ValueOf uni b -> Maybe (a :~: b) Source #

( GCompare uni, Closed uni, Everywhere uni Ord , Everywhere uni Eq ) => GCompare ( ValueOf uni :: Type -> Type ) Source #
Instance details

Defined in Universe.Core

Methods

gcompare :: forall (a :: k) (b :: k). ValueOf uni a -> ValueOf uni b -> GOrdering a b Source #

( Closed uni, Everywhere uni NFData ) => GNFData ( ValueOf uni) Source #
Instance details

Defined in Universe.Core

Methods

grnf :: ValueOf uni a -> () Source #

( GEq uni, Closed uni, Everywhere uni Eq ) => Eq ( ValueOf uni a) Source #
Instance details

Defined in Universe.Core

( GCompare uni, Closed uni, Everywhere uni Ord , Everywhere uni Eq ) => Ord ( ValueOf uni a) Source #
Instance details

Defined in Universe.Core

( GShow uni, Closed uni, Everywhere uni Show ) => Show ( ValueOf uni a) Source #
Instance details

Defined in Universe.Core

( Closed uni, Everywhere uni NFData ) => NFData ( ValueOf uni a) Source #
Instance details

Defined in Universe.Core

Methods

rnf :: ValueOf uni a -> () Source #

( Closed uni, Everywhere uni Flat ) => Flat ( Some ( ValueOf uni)) Source #
Instance details

Defined in PlutusCore.Flat

( Closed uni, Everywhere uni PrettyConst ) => Pretty ( Some ( ValueOf uni)) Source #
Instance details

Defined in PlutusCore.Pretty.PrettyConst

( Closed uni, Everywhere uni PrettyConst ) => Pretty ( ValueOf uni a) Source #

Special treatment for built-in constants: see the Note in PlutusCore.Pretty.PrettyConst.

Instance details

Defined in PlutusCore.Pretty.PrettyConst

( Closed uni, Everywhere uni ExMemoryUsage ) => ExMemoryUsage ( Some ( ValueOf uni)) Source #
Instance details

Defined in PlutusCore.Evaluation.Machine.ExMemory

someValueOf :: forall a uni. uni ( Esc a) -> a -> Some ( ValueOf uni) Source #

Wrap a value into Some (ValueOf uni) , given its explicit type tag.

someValue :: forall a uni. uni `Includes` a => a -> Some ( ValueOf uni) Source #

Wrap a value into Some (ValueOf uni) , provided its type is in the universe.

data Esc a Source #

"Escapes" a type of an arbitrary kind to fit into Type .

class Contains uni a where Source #

A class for enumerating types and fully instantiated type formers that uni contains. For example, a particular ExampleUni may have monomorphic types in it:

instance ExampleUni Contains Integer where ... instance ExampleUni Contains Bool where ...

as well as polymorphic ones:

instance ExampleUni Contains [] where ... instance ExampleUni Contains (,) where ...

as well as their instantiations:

instance ExampleUni Contains a => ExampleUni Contains [a] where ... instance (ExampleUni Contains a, ExampleUni Contains b) => ExampleUni Contains (a, b) where ...

(a universe can have any subset of the mentioned sorts of types, for example it's fine to have instantiated polymorphic types and not have uninstantiated ones and vice versa)

Note that when used as a constraint of a function Contains does not allow you to directly express things like " uni has the Integer , Bool and [] types and type formers", because [] is not fully instantiated. So you can only say " uni has Integer , Bool , [Integer] , [Bool] , [[Integer]] , [[Bool]] etc" and such manual enumeration is annoying, so we'd really like to be able to say that uni has lists of arbitrary built-in types (including lists of lists etc). Contains does not allow that, but Includes does. For example, in the body of the following definition:

foo :: (uni Includes Integer, uni Includes Bool, uni Includes []) => ... foo = ...

you can make use of the fact that uni has lists of arbitrary included types (integers, booleans and lists).

Hence most of the time opt for using the more flexible Includes .

Includes is defined in terms of Contains , so you only need to provide a Contains instance per type from the universe and you'll get Includes for free.

Instances

Instances details
( Contains DefaultUni f, Contains DefaultUni a) => Contains DefaultUni (f a :: k2) Source #
Instance details

Defined in PlutusCore.Default.Universe

Contains DefaultUni Bool Source #
Instance details

Defined in PlutusCore.Default.Universe

Contains DefaultUni Integer Source #
Instance details

Defined in PlutusCore.Default.Universe

Contains DefaultUni () Source #
Instance details

Defined in PlutusCore.Default.Universe

Contains DefaultUni ByteString Source #
Instance details

Defined in PlutusCore.Default.Universe

Contains DefaultUni Text Source #
Instance details

Defined in PlutusCore.Default.Universe

Contains DefaultUni Data Source #
Instance details

Defined in PlutusCore.Default.Universe

Contains DefaultUni (,) Source #
Instance details

Defined in PlutusCore.Default.Universe

Contains DefaultUni [] Source #
Instance details

Defined in PlutusCore.Default.Universe

( TypeError NoStandalonePolymorphicDataErrMsg :: Constraint ) => Contains uni ( TyVarRep :: TyNameRep kind -> kind) Source #
Instance details

Defined in PlutusCore.Builtin.Polymorphism

type Includes uni = Permits ( Contains uni) Source #

uni Includes a reads as " a is in the uni ". a can be of a higher-kind, see the docs of Contains on why you might want that.

class Closed uni where Source #

A universe is Closed , if it's known how to constrain every type from the universe and every type can be encoded to / decoded from a sequence of integer tags. The universe doesn't have to be finite and providing support for infinite universes is the reason why we encode a type as a sequence of integer tags as opposed to a single integer tag. For example, given

  data U a where
      UList :: !(U a) -> U [a]
      UInt  :: U Int

UList (UList UInt) can be encoded to [0,0,1] where 0 and 1 are the integer tags of the UList and UInt constructors, respectively.

Associated Types

type Everywhere uni (constr :: Type -> Constraint ) :: Constraint Source #

A constrant for " constr a holds for any a from uni ".

Methods

encodeUni :: uni a -> [ Int ] Source #

Encode a type as a sequence of Int tags. The opposite of decodeUni .

withDecodedUni :: ( forall k (a :: k). Typeable k => uni ( Esc a) -> DecodeUniM r) -> DecodeUniM r Source #

Decode a type and feed it to the continuation.

bring :: uni `Everywhere` constr => proxy constr -> uni ( Esc a) -> (constr a => r) -> r Source #

Bring a constr a instance in scope, provided a is a type from the universe and constr holds for any type from the universe.

type family EverywhereAll uni constrs where ... Source #

Equations

EverywhereAll uni '[] = ()
EverywhereAll uni (constr ': constrs) = (uni `Everywhere` constr, uni `EverywhereAll` constrs)

knownUniOf :: uni `Contains` a => proxy a -> uni ( Esc a) Source #

Same as knownUni , but receives a proxy .

class GShow (t :: k -> Type ) where Source #

Show -like class for 1-type-parameter GADTs. GShow t => ... is equivalent to something like (forall a. Show (t a)) => ... . The easiest way to create instances would probably be to write (or derive) an instance Show (T a) , and then simply say:

instance GShow t where gshowsPrec = showsPrec

Methods

gshowsPrec :: forall (a :: k). Int -> t a -> ShowS Source #

Instances

Instances details
GShow DefaultUni Source #
Instance details

Defined in PlutusCore.Default.Universe

( GShow uni, Closed uni, Everywhere uni Show ) => GShow ( ValueOf uni :: Type -> Type ) Source #
Instance details

Defined in Universe.Core

Methods

gshowsPrec :: forall (a :: k). Int -> ValueOf uni a -> ShowS Source #

GShow uni => GShow ( Kinded uni :: Type -> Type ) Source #
Instance details

Defined in Universe.Core

Methods

gshowsPrec :: forall (a :: k). Int -> Kinded uni a -> ShowS Source #

GShow ( TypeRep :: k -> Type )
Instance details

Defined in Data.GADT.Internal

Methods

gshowsPrec :: forall (a :: k0). Int -> TypeRep a -> ShowS Source #

GShow ( GOrdering a :: k -> Type )
Instance details

Defined in Data.GADT.Internal

Methods

gshowsPrec :: forall (a0 :: k0). Int -> GOrdering a a0 -> ShowS Source #

GShow ( (:~:) a :: k -> Type )
Instance details

Defined in Data.GADT.Internal

Methods

gshowsPrec :: forall (a0 :: k0). Int -> (a :~: a0) -> ShowS Source #

( GShow a, GShow b) => GShow ( Sum a b :: k -> Type )
>>> gshow (InL Refl :: Sum ((:~:) Int) ((:~:) Bool) Int)
"InL Refl"
Instance details

Defined in Data.GADT.Internal

Methods

gshowsPrec :: forall (a0 :: k0). Int -> Sum a b a0 -> ShowS Source #

( GShow a, GShow b) => GShow ( Product a b :: k -> Type )
>>> gshow (Pair Refl Refl :: Product ((:~:) Int) ((:~:) Int) Int)
"Pair Refl Refl"
Instance details

Defined in Data.GADT.Internal

Methods

gshowsPrec :: forall (a0 :: k0). Int -> Product a b a0 -> ShowS Source #

show :: Show a => a -> String Source #

A specialised variant of showsPrec , using precedence context zero, and returning an ordinary String .

class GEq (f :: k -> Type ) where Source #

A class for type-contexts which contain enough information to (at least in some cases) decide the equality of types occurring within them.

Methods

geq :: forall (a :: k) (b :: k). f a -> f b -> Maybe (a :~: b) Source #

Produce a witness of type-equality, if one exists.

A handy idiom for using this would be to pattern-bind in the Maybe monad, eg.:

extract :: GEq tag => tag a -> DSum tag -> Maybe a
extract t1 (t2 :=> x) = do
    Refl <- geq t1 t2
    return x

Or in a list comprehension:

extractMany :: GEq tag => tag a -> [DSum tag] -> [a]
extractMany t1 things = [ x | (t2 :=> x) <- things, Refl <- maybeToList (geq t1 t2)]

(Making use of the DSum type from Data.Dependent.Sum in both examples)

Instances

Instances details
GEq DefaultUni Source #
Instance details

Defined in PlutusCore.Default.Universe

Methods

geq :: forall (a :: k) (b :: k). DefaultUni a -> DefaultUni b -> Maybe (a :~: b) Source #

( GEq uni, Closed uni, Everywhere uni Eq ) => GEq ( ValueOf uni :: Type -> Type ) Source #
Instance details

Defined in Universe.Core

Methods

geq :: forall (a :: k) (b :: k). ValueOf uni a -> ValueOf uni b -> Maybe (a :~: b) Source #

GEq ( TypeRep :: k -> Type )
Instance details

Defined in Data.GADT.Internal

Methods

geq :: forall (a :: k0) (b :: k0). TypeRep a -> TypeRep b -> Maybe (a :~: b) Source #

GEq ( (:~:) a :: k -> Type )
Instance details

Defined in Data.GADT.Internal

Methods

geq :: forall (a0 :: k0) (b :: k0). (a :~: a0) -> (a :~: b) -> Maybe (a0 :~: b) Source #

( GEq a, GEq b) => GEq ( Sum a b :: k -> Type )
Instance details

Defined in Data.GADT.Internal

Methods

geq :: forall (a0 :: k0) (b0 :: k0). Sum a b a0 -> Sum a b b0 -> Maybe (a0 :~: b0) Source #

( GEq a, GEq b) => GEq ( Product a b :: k -> Type )
Instance details

Defined in Data.GADT.Internal

Methods

geq :: forall (a0 :: k0) (b0 :: k0). Product a b a0 -> Product a b b0 -> Maybe (a0 :~: b0) Source #

class HasUniApply (uni :: Type -> Type ) where Source #

A class for " uni has general type application".

Methods

matchUniApply Source #

Arguments

:: uni tb

The type.

-> r

What to return if the type is not an application.

-> ( forall k l (f :: k -> l) a. tb ~ Esc (f a) => uni ( Esc f) -> uni ( Esc a) -> r)

The continuation taking a function and an argument.

-> r

Deconstruct a type application into the function and the argument and feed them to the continuation. If the type is not an application, then return the default value.

Instances

Instances details
HasUniApply DefaultUni Source #
Instance details

Defined in PlutusCore.Default.Universe

Methods

matchUniApply :: DefaultUni tb -> r -> ( forall k l (f :: k -> l) (a :: k). tb ~ Esc (f a) => DefaultUni ( Esc f) -> DefaultUni ( Esc a) -> r) -> r Source #

checkStar :: forall uni a (x :: a). Typeable a => uni ( Esc x) -> Maybe (a :~: Type ) Source #

Check if the kind of the given type from the universe is Type .

withApplicable :: forall (a :: Type ) (ab :: Type ) f x uni m r. ( Typeable ab, Typeable a, MonadPlus m) => uni ( Esc (f :: ab)) -> uni ( Esc (x :: a)) -> ( forall (b :: Type ). ( Typeable b, ab ~ (a -> b)) => m r) -> m r Source #

Check if one type from the universe can be applied to another (i.e. check that the expected kind of the argument matches the actual one) and call the continuation in the refined context. Fail with mzero otherwise.

data (a :: k) :~: (b :: k) where infix 4 Source #

Propositional equality. If a :~: b is inhabited by some terminating value, then the type a is the same as the type b . To use this equality in practice, pattern-match on the a :~: b to get out the Refl constructor; in the body of the pattern-match, the compiler knows that a ~ b .

Since: base-4.7.0.0

Constructors

Refl :: forall k (a :: k). a :~: a

Instances

Instances details
Category ( (:~:) :: k -> k -> Type )

Since: base-4.7.0.0

Instance details

Defined in Control.Category

Methods

id :: forall (a :: k0). a :~: a Source #

(.) :: forall (b :: k0) (c :: k0) (a :: k0). (b :~: c) -> (a :~: b) -> a :~: c Source #

Semigroupoid ( (:~:) :: k -> k -> Type )
Instance details

Defined in Data.Semigroupoid

Methods

o :: forall (j :: k0) (k1 :: k0) (i :: k0). (j :~: k1) -> (i :~: j) -> i :~: k1 Source #

TestEquality ( (:~:) a :: k -> Type )

Since: base-4.7.0.0

Instance details

Defined in Data.Type.Equality

Methods

testEquality :: forall (a0 :: k0) (b :: k0). (a :~: a0) -> (a :~: b) -> Maybe (a0 :~: b) Source #

GShow ( (:~:) a :: k -> Type )
Instance details

Defined in Data.GADT.Internal

Methods

gshowsPrec :: forall (a0 :: k0). Int -> (a :~: a0) -> ShowS Source #

GRead ( (:~:) a :: k -> Type )
Instance details

Defined in Data.GADT.Internal

GEq ( (:~:) a :: k -> Type )
Instance details

Defined in Data.GADT.Internal

Methods

geq :: forall (a0 :: k0) (b :: k0). (a :~: a0) -> (a :~: b) -> Maybe (a0 :~: b) Source #

GCompare ( (:~:) a :: k -> Type )
Instance details

Defined in Data.GADT.Internal

Methods

gcompare :: forall (a0 :: k0) (b :: k0). (a :~: a0) -> (a :~: b) -> GOrdering a0 b Source #

NFData2 ( (:~:) :: Type -> Type -> Type )

Since: deepseq-1.4.3.0

Instance details

Defined in Control.DeepSeq

Methods

liftRnf2 :: (a -> ()) -> (b -> ()) -> (a :~: b) -> () Source #

NFData1 ( (:~:) a)

Since: deepseq-1.4.3.0

Instance details

Defined in Control.DeepSeq

Methods

liftRnf :: (a0 -> ()) -> (a :~: a0) -> () Source #

a ~ b => Bounded (a :~: b)

Since: base-4.7.0.0

Instance details

Defined in Data.Type.Equality

a ~ b => Enum (a :~: b)

Since: base-4.7.0.0

Instance details

Defined in Data.Type.Equality

Eq (a :~: b)

Since: base-4.7.0.0

Instance details

Defined in Data.Type.Equality

(a ~ b, Data a) => Data (a :~: b)

Since: base-4.7.0.0

Instance details

Defined in Data.Data

Methods

gfoldl :: ( forall d b0. Data d => c (d -> b0) -> d -> c b0) -> ( forall g. g -> c g) -> (a :~: b) -> c (a :~: b) Source #

gunfold :: ( forall b0 r. Data b0 => c (b0 -> r) -> c r) -> ( forall r. r -> c r) -> Constr -> c (a :~: b) Source #

toConstr :: (a :~: b) -> Constr Source #

dataTypeOf :: (a :~: b) -> DataType Source #

dataCast1 :: Typeable t => ( forall d. Data d => c (t d)) -> Maybe (c (a :~: b)) Source #

dataCast2 :: Typeable t => ( forall d e. ( Data d, Data e) => c (t d e)) -> Maybe (c (a :~: b)) Source #

gmapT :: ( forall b0. Data b0 => b0 -> b0) -> (a :~: b) -> a :~: b Source #

gmapQl :: (r -> r' -> r) -> r -> ( forall d. Data d => d -> r') -> (a :~: b) -> r Source #

gmapQr :: forall r r'. (r' -> r -> r) -> r -> ( forall d. Data d => d -> r') -> (a :~: b) -> r Source #

gmapQ :: ( forall d. Data d => d -> u) -> (a :~: b) -> [u] Source #

gmapQi :: Int -> ( forall d. Data d => d -> u) -> (a :~: b) -> u Source #

gmapM :: Monad m => ( forall d. Data d => d -> m d) -> (a :~: b) -> m (a :~: b) Source #

gmapMp :: MonadPlus m => ( forall d. Data d => d -> m d) -> (a :~: b) -> m (a :~: b) Source #

gmapMo :: MonadPlus m => ( forall d. Data d => d -> m d) -> (a :~: b) -> m (a :~: b) Source #

Ord (a :~: b)

Since: base-4.7.0.0

Instance details

Defined in Data.Type.Equality

a ~ b => Read (a :~: b)

Since: base-4.7.0.0

Instance details

Defined in Data.Type.Equality

Show (a :~: b)

Since: base-4.7.0.0

Instance details

Defined in Data.Type.Equality

NFData (a :~: b)

Since: deepseq-1.4.3.0

Instance details

Defined in Control.DeepSeq

Methods

rnf :: (a :~: b) -> () Source #

type (<:) uni1 uni2 = uni1 `Everywhere` Includes uni2 Source #

A constraint for " uni1 is a subuniverse of uni2 ".

data DefaultUni a where Source #

The universe used by default.

Instances

Instances details
HasUniApply DefaultUni Source #
Instance details

Defined in PlutusCore.Default.Universe

Methods

matchUniApply :: DefaultUni tb -> r -> ( forall k l (f :: k -> l) (a :: k). tb ~ Esc (f a) => DefaultUni ( Esc f) -> DefaultUni ( Esc a) -> r) -> r Source #

Closed DefaultUni Source #
Instance details

Defined in PlutusCore.Default.Universe

Associated Types

type Everywhere DefaultUni constr Source #

ToKind DefaultUni Source #
Instance details

Defined in PlutusCore.Default.Universe

Methods

toSingKind :: forall k (a :: k). DefaultUni ( Esc a) -> SingKind k Source #

TestTypesFromTheUniverseAreAllKnown DefaultUni Source #
Instance details

Defined in PlutusCore.Default.Universe

GShow DefaultUni Source #
Instance details

Defined in PlutusCore.Default.Universe

GEq DefaultUni Source #
Instance details

Defined in PlutusCore.Default.Universe

Methods

geq :: forall (a :: k) (b :: k). DefaultUni a -> DefaultUni b -> Maybe (a :~: b) Source #

GCompare DefaultUni Source #
Instance details

Defined in PlutusCore.Default.Universe

Methods

gcompare :: forall (a :: k) (b :: k). DefaultUni a -> DefaultUni b -> GOrdering a b Source #

HasConstantIn DefaultUni term => ReadKnownIn DefaultUni term Int Source #
Instance details

Defined in PlutusCore.Default.Universe

HasConstantIn DefaultUni term => ReadKnownIn DefaultUni term Int64 Source #
Instance details

Defined in PlutusCore.Default.Universe

HasConstantIn DefaultUni term => ReadKnownIn DefaultUni term Data Source #
Instance details

Defined in PlutusCore.Default.Universe

HasConstantIn DefaultUni term => ReadKnownIn DefaultUni term Bool Source #
Instance details

Defined in PlutusCore.Default.Universe

HasConstantIn DefaultUni term => ReadKnownIn DefaultUni term () Source #
Instance details

Defined in PlutusCore.Default.Universe

Methods

readKnown :: Maybe cause -> term -> ReadKnownM cause () Source #

HasConstantIn DefaultUni term => ReadKnownIn DefaultUni term Text Source #
Instance details

Defined in PlutusCore.Default.Universe

HasConstantIn DefaultUni term => ReadKnownIn DefaultUni term ByteString Source #
Instance details

Defined in PlutusCore.Default.Universe

HasConstantIn DefaultUni term => ReadKnownIn DefaultUni term Integer Source #
Instance details

Defined in PlutusCore.Default.Universe

UniOf term ~ DefaultUni => ReadKnownIn DefaultUni term Void Source #
Instance details

Defined in PlutusCore.Examples.Builtins

HasConstantIn DefaultUni term => MakeKnownIn DefaultUni term Int Source #
Instance details

Defined in PlutusCore.Default.Universe

HasConstantIn DefaultUni term => MakeKnownIn DefaultUni term Int64 Source #
Instance details

Defined in PlutusCore.Default.Universe

HasConstantIn DefaultUni term => MakeKnownIn DefaultUni term Data Source #
Instance details

Defined in PlutusCore.Default.Universe

HasConstantIn DefaultUni term => MakeKnownIn DefaultUni term Bool Source #
Instance details

Defined in PlutusCore.Default.Universe

HasConstantIn DefaultUni term => MakeKnownIn DefaultUni term () Source #
Instance details

Defined in PlutusCore.Default.Universe

Methods

makeKnown :: Maybe cause -> () -> MakeKnownM cause term Source #

HasConstantIn DefaultUni term => MakeKnownIn DefaultUni term Text Source #
Instance details

Defined in PlutusCore.Default.Universe

HasConstantIn DefaultUni term => MakeKnownIn DefaultUni term ByteString Source #
Instance details

Defined in PlutusCore.Default.Universe

HasConstantIn DefaultUni term => MakeKnownIn DefaultUni term Integer Source #
Instance details

Defined in PlutusCore.Default.Universe

UniOf term ~ DefaultUni => MakeKnownIn DefaultUni term Void Source #
Instance details

Defined in PlutusCore.Examples.Builtins

( Contains DefaultUni f, Contains DefaultUni a) => Contains DefaultUni (f a :: k2) Source #
Instance details

Defined in PlutusCore.Default.Universe

( HasConstantIn DefaultUni term, Contains DefaultUni [a]) => ReadKnownIn DefaultUni term [a] Source #
Instance details

Defined in PlutusCore.Default.Universe

Methods

readKnown :: Maybe cause -> term -> ReadKnownM cause [a] Source #

( HasConstantIn DefaultUni term, Contains DefaultUni [a]) => MakeKnownIn DefaultUni term [a] Source #
Instance details

Defined in PlutusCore.Default.Universe

Methods

makeKnown :: Maybe cause -> [a] -> MakeKnownM cause term Source #

( HasConstantIn DefaultUni term, Contains DefaultUni (a, b)) => ReadKnownIn DefaultUni term (a, b) Source #
Instance details

Defined in PlutusCore.Default.Universe

Methods

readKnown :: Maybe cause -> term -> ReadKnownM cause (a, b) Source #

( HasConstantIn DefaultUni term, Contains DefaultUni (a, b)) => MakeKnownIn DefaultUni term (a, b) Source #
Instance details

Defined in PlutusCore.Default.Universe

Methods

makeKnown :: Maybe cause -> (a, b) -> MakeKnownM cause term Source #

Show ( DefaultUni a) Source #
Instance details

Defined in PlutusCore.Default.Universe

Contains DefaultUni Bool Source #
Instance details

Defined in PlutusCore.Default.Universe

Contains DefaultUni Integer Source #
Instance details

Defined in PlutusCore.Default.Universe

Contains DefaultUni () Source #
Instance details

Defined in PlutusCore.Default.Universe

Contains DefaultUni ByteString Source #
Instance details

Defined in PlutusCore.Default.Universe

Contains DefaultUni Text Source #
Instance details

Defined in PlutusCore.Default.Universe

Contains DefaultUni Data Source #
Instance details

Defined in PlutusCore.Default.Universe

KnownBuiltinTypeAst DefaultUni Bool => KnownTypeAst DefaultUni Bool Source #
Instance details

Defined in PlutusCore.Default.Universe

KnownTypeAst DefaultUni Int Source #
Instance details

Defined in PlutusCore.Default.Universe

KnownTypeAst DefaultUni Int64 Source #
Instance details

Defined in PlutusCore.Default.Universe

KnownBuiltinTypeAst DefaultUni Integer => KnownTypeAst DefaultUni Integer Source #
Instance details

Defined in PlutusCore.Default.Universe

KnownBuiltinTypeAst DefaultUni () => KnownTypeAst DefaultUni () Source #
Instance details

Defined in PlutusCore.Default.Universe

KnownBuiltinTypeAst DefaultUni ByteString => KnownTypeAst DefaultUni ByteString Source #
Instance details

Defined in PlutusCore.Default.Universe

KnownBuiltinTypeAst DefaultUni Text => KnownTypeAst DefaultUni Text Source #
Instance details

Defined in PlutusCore.Default.Universe

KnownTypeAst DefaultUni Void Source #
Instance details

Defined in PlutusCore.Examples.Builtins

KnownBuiltinTypeAst DefaultUni Data => KnownTypeAst DefaultUni Data Source #
Instance details

Defined in PlutusCore.Default.Universe

KnownBuiltinTypeAst DefaultUni [a] => KnownTypeAst DefaultUni ([a] :: Type ) Source #
Instance details

Defined in PlutusCore.Default.Universe

KnownBuiltinTypeAst DefaultUni (a, b) => KnownTypeAst DefaultUni ((a, b) :: Type ) Source #
Instance details

Defined in PlutusCore.Default.Universe

Associated Types

type ToHoles (a, b) :: [ Hole ] Source #

type ToBinds (a, b) :: [ Some TyNameRep ] Source #

Contains DefaultUni (,) Source #
Instance details

Defined in PlutusCore.Default.Universe

Contains DefaultUni [] Source #
Instance details

Defined in PlutusCore.Default.Universe

type Everywhere DefaultUni constr Source #
Instance details

Defined in PlutusCore.Default.Universe

pattern DefaultUniList :: forall a k1 k2 (f :: k1 -> k2) (a1 :: k1). () => forall . (a ~ Esc (f a1), Esc f ~ Esc []) => DefaultUni ( Esc a1) -> DefaultUni a Source #

pattern DefaultUniPair :: forall a k1 k2 (f1 :: k1 -> k2) (a1 :: k1) k3 k4 (f2 :: k3 -> k4) (a2 :: k3). () => forall . (a ~ Esc (f1 a1), Esc f1 ~ Esc (f2 a2), Esc f2 ~ Esc (,) ) => DefaultUni ( Esc a2) -> DefaultUni ( Esc a1) -> DefaultUni a Source #

data DefaultFun Source #

Default built-in functions.

When updating these, make sure to add them to the protocol version listing! See Note [New builtins and protocol versions]

Instances

Instances details
Bounded DefaultFun Source #
Instance details

Defined in PlutusCore.Default.Builtins

Enum DefaultFun Source #
Instance details

Defined in PlutusCore.Default.Builtins

Eq DefaultFun Source #
Instance details

Defined in PlutusCore.Default.Builtins

Ord DefaultFun Source #
Instance details

Defined in PlutusCore.Default.Builtins

Show DefaultFun Source #
Instance details

Defined in PlutusCore.Default.Builtins

Ix DefaultFun Source #
Instance details

Defined in PlutusCore.Default.Builtins

Generic DefaultFun Source #
Instance details

Defined in PlutusCore.Default.Builtins

Hashable DefaultFun Source #
Instance details

Defined in PlutusCore.Default.Builtins

NFData DefaultFun Source #
Instance details

Defined in PlutusCore.Default.Builtins

Flat DefaultFun Source #
Instance details

Defined in PlutusCore.Default.Builtins

Pretty DefaultFun Source #
Instance details

Defined in PlutusCore.Default.Builtins

ExMemoryUsage DefaultFun Source #
Instance details

Defined in PlutusCore.Default.Builtins

PrettyBy PrettyConfigPlc DefaultFun Source #
Instance details

Defined in PlutusCore.Default.Builtins

uni ~ DefaultUni => ToBuiltinMeaning uni DefaultFun Source #
Instance details

Defined in PlutusCore.Default.Builtins

type Rep DefaultFun Source #
Instance details

Defined in PlutusCore.Default.Builtins

type Rep DefaultFun = D1 (' MetaData "DefaultFun" "PlutusCore.Default.Builtins" "plutus-core-1.0.0.1-76bWF9ZEWyb4eDyjHx0kCS" ' False ) ((((( C1 (' MetaCons "AddInteger" ' PrefixI ' False ) ( U1 :: Type -> Type ) :+: ( C1 (' MetaCons "SubtractInteger" ' PrefixI ' False ) ( U1 :: Type -> Type ) :+: C1 (' MetaCons "MultiplyInteger" ' PrefixI ' False ) ( U1 :: Type -> Type ))) :+: ( C1 (' MetaCons "DivideInteger" ' PrefixI ' False ) ( U1 :: Type -> Type ) :+: ( C1 (' MetaCons "QuotientInteger" ' PrefixI ' False ) ( U1 :: Type -> Type ) :+: C1 (' MetaCons "RemainderInteger" ' PrefixI ' False ) ( U1 :: Type -> Type )))) :+: (( C1 (' MetaCons "ModInteger" ' PrefixI ' False ) ( U1 :: Type -> Type ) :+: ( C1 (' MetaCons "EqualsInteger" ' PrefixI ' False ) ( U1 :: Type -> Type ) :+: C1 (' MetaCons "LessThanInteger" ' PrefixI ' False ) ( U1 :: Type -> Type ))) :+: (( C1 (' MetaCons "LessThanEqualsInteger" ' PrefixI ' False ) ( U1 :: Type -> Type ) :+: C1 (' MetaCons "AppendByteString" ' PrefixI ' False ) ( U1 :: Type -> Type )) :+: ( C1 (' MetaCons "ConsByteString" ' PrefixI ' False ) ( U1 :: Type -> Type ) :+: C1 (' MetaCons "SliceByteString" ' PrefixI ' False ) ( U1 :: Type -> Type ))))) :+: ((( C1 (' MetaCons "LengthOfByteString" ' PrefixI ' False ) ( U1 :: Type -> Type ) :+: ( C1 (' MetaCons "IndexByteString" ' PrefixI ' False ) ( U1 :: Type -> Type ) :+: C1 (' MetaCons "EqualsByteString" ' PrefixI ' False ) ( U1 :: Type -> Type ))) :+: (( C1 (' MetaCons "LessThanByteString" ' PrefixI ' False ) ( U1 :: Type -> Type ) :+: C1 (' MetaCons "LessThanEqualsByteString" ' PrefixI ' False ) ( U1 :: Type -> Type )) :+: ( C1 (' MetaCons "Sha2_256" ' PrefixI ' False ) ( U1 :: Type -> Type ) :+: C1 (' MetaCons "Sha3_256" ' PrefixI ' False ) ( U1 :: Type -> Type )))) :+: (( C1 (' MetaCons "Blake2b_256" ' PrefixI ' False ) ( U1 :: Type -> Type ) :+: ( C1 (' MetaCons "VerifyEd25519Signature" ' PrefixI ' False ) ( U1 :: Type -> Type ) :+: C1 (' MetaCons "VerifyEcdsaSecp256k1Signature" ' PrefixI ' False ) ( U1 :: Type -> Type ))) :+: (( C1 (' MetaCons "VerifySchnorrSecp256k1Signature" ' PrefixI ' False ) ( U1 :: Type -> Type ) :+: C1 (' MetaCons "AppendString" ' PrefixI ' False ) ( U1 :: Type -> Type )) :+: ( C1 (' MetaCons "EqualsString" ' PrefixI ' False ) ( U1 :: Type -> Type ) :+: C1 (' MetaCons "EncodeUtf8" ' PrefixI ' False ) ( U1 :: Type -> Type )))))) :+: (((( C1 (' MetaCons "DecodeUtf8" ' PrefixI ' False ) ( U1 :: Type -> Type ) :+: ( C1 (' MetaCons "IfThenElse" ' PrefixI ' False ) ( U1 :: Type -> Type ) :+: C1 (' MetaCons "ChooseUnit" ' PrefixI ' False ) ( U1 :: Type -> Type ))) :+: ( C1 (' MetaCons "Trace" ' PrefixI ' False ) ( U1 :: Type -> Type ) :+: ( C1 (' MetaCons "FstPair" ' PrefixI ' False ) ( U1 :: Type -> Type ) :+: C1 (' MetaCons "SndPair" ' PrefixI ' False ) ( U1 :: Type -> Type )))) :+: (( C1 (' MetaCons "ChooseList" ' PrefixI ' False ) ( U1 :: Type -> Type ) :+: ( C1 (' MetaCons "MkCons" ' PrefixI ' False ) ( U1 :: Type -> Type ) :+: C1 (' MetaCons "HeadList" ' PrefixI ' False ) ( U1 :: Type -> Type ))) :+: (( C1 (' MetaCons "TailList" ' PrefixI ' False ) ( U1 :: Type -> Type ) :+: C1 (' MetaCons "NullList" ' PrefixI ' False ) ( U1 :: Type -> Type )) :+: ( C1 (' MetaCons "ChooseData" ' PrefixI ' False ) ( U1 :: Type -> Type ) :+: C1 (' MetaCons "ConstrData" ' PrefixI ' False ) ( U1 :: Type -> Type ))))) :+: ((( C1 (' MetaCons "MapData" ' PrefixI ' False ) ( U1 :: Type -> Type ) :+: ( C1 (' MetaCons "ListData" ' PrefixI ' False ) ( U1 :: Type -> Type ) :+: C1 (' MetaCons "IData" ' PrefixI ' False ) ( U1 :: Type -> Type ))) :+: (( C1 (' MetaCons "BData" ' PrefixI ' False ) ( U1 :: Type -> Type ) :+: C1 (' MetaCons "UnConstrData" ' PrefixI ' False ) ( U1 :: Type -> Type )) :+: ( C1 (' MetaCons "UnMapData" ' PrefixI ' False ) ( U1 :: Type -> Type ) :+: C1 (' MetaCons "UnListData" ' PrefixI ' False ) ( U1 :: Type -> Type )))) :+: (( C1 (' MetaCons "UnIData" ' PrefixI ' False ) ( U1 :: Type -> Type ) :+: ( C1 (' MetaCons "UnBData" ' PrefixI ' False ) ( U1 :: Type -> Type ) :+: C1 (' MetaCons "EqualsData" ' PrefixI ' False ) ( U1 :: Type -> Type ))) :+: (( C1 (' MetaCons "SerialiseData" ' PrefixI ' False ) ( U1 :: Type -> Type ) :+: C1 (' MetaCons "MkPairData" ' PrefixI ' False ) ( U1 :: Type -> Type )) :+: ( C1 (' MetaCons "MkNilData" ' PrefixI ' False ) ( U1 :: Type -> Type ) :+: C1 (' MetaCons "MkNilPairData" ' PrefixI ' False ) ( U1 :: Type -> Type )))))))
type CostingPart uni DefaultFun Source #
Instance details

Defined in PlutusCore.Default.Builtins

AST

data Term tyname name uni fun ann Source #

Constructors

Var ann name

a named variable

TyAbs ann tyname ( Kind ann) ( Term tyname name uni fun ann)
LamAbs ann name ( Type tyname uni ann) ( Term tyname name uni fun ann)
Apply ann ( Term tyname name uni fun ann) ( Term tyname name uni fun ann)
Constant ann ( Some ( ValueOf uni))

a constant term

Builtin ann fun
TyInst ann ( Term tyname name uni fun ann) ( Type tyname uni ann)
Unwrap ann ( Term tyname name uni fun ann)
IWrap ann ( Type tyname uni ann) ( Type tyname uni ann) ( Term tyname name uni fun ann)
Error ann ( Type tyname uni ann)

Instances

Instances details
tyname ~ TyName => Reference TyName ( Term tyname name uni fun) Source #
Instance details

Defined in PlutusCore.Core.Instance.Scoping

Methods

referenceVia :: ( forall name0. ToScopedName name0 => name0 -> NameAnn ) -> TyName -> Term tyname name uni fun NameAnn -> Term tyname name uni fun NameAnn Source #

name ~ Name => Reference Name ( Term tyname name uni fun) Source #
Instance details

Defined in PlutusCore.Core.Instance.Scoping

Methods

referenceVia :: ( forall name0. ToScopedName name0 => name0 -> NameAnn ) -> Name -> Term tyname name uni fun NameAnn -> Term tyname name uni fun NameAnn Source #

DefaultPrettyPlcStrategy ( Term tyname name uni fun ann) => PrettyBy PrettyConfigPlc ( Term tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Pretty.Plc

Methods

prettyBy :: PrettyConfigPlc -> Term tyname name uni fun ann -> Doc ann0 Source #

prettyListBy :: PrettyConfigPlc -> [ Term tyname name uni fun ann] -> Doc ann0 Source #

( PrettyReadableBy configName tyname, PrettyReadableBy configName name, GShow uni, Closed uni, Everywhere uni PrettyConst , Pretty fun) => PrettyBy ( PrettyConfigReadable configName) ( Term tyname name uni fun a) Source #
Instance details

Defined in PlutusCore.Core.Instance.Pretty.Readable

Methods

prettyBy :: PrettyConfigReadable configName -> Term tyname name uni fun a -> Doc ann Source #

prettyListBy :: PrettyConfigReadable configName -> [ Term tyname name uni fun a] -> Doc ann Source #

( PrettyClassicBy configName tyname, PrettyClassicBy configName name, GShow uni, Closed uni, Everywhere uni PrettyConst , Pretty fun, Pretty ann) => PrettyBy ( PrettyConfigClassic configName) ( Term tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Pretty.Classic

Methods

prettyBy :: PrettyConfigClassic configName -> Term tyname name uni fun ann -> Doc ann0 Source #

prettyListBy :: PrettyConfigClassic configName -> [ Term tyname name uni fun ann] -> Doc ann0 Source #

AsTypeError ( Error uni fun ann) ( Term TyName Name uni fun ()) uni fun ann Source #
Instance details

Defined in PlutusCore.Error

Functor ( Term tyname name uni fun) Source #
Instance details

Defined in PlutusCore.Core.Type

Methods

fmap :: (a -> b) -> Term tyname name uni fun a -> Term tyname name uni fun b Source #

(<$) :: a -> Term tyname name uni fun b -> Term tyname name uni fun a Source #

(tyname ~ TyName , name ~ Name ) => CollectScopeInfo ( Term tyname name uni fun) Source #
Instance details

Defined in PlutusCore.Core.Instance.Scoping

(tyname ~ TyName , name ~ Name ) => EstablishScoping ( Term tyname name uni fun) Source #
Instance details

Defined in PlutusCore.Core.Instance.Scoping

Methods

establishScoping :: Term tyname name uni fun ann -> Quote ( Term tyname name uni fun NameAnn ) Source #

TermLike ( Term tyname name uni fun) tyname name uni fun Source #
Instance details

Defined in PlutusCore.MkPlc

Methods

var :: ann -> name -> Term tyname name uni fun ann Source #

tyAbs :: ann -> tyname -> Kind ann -> Term tyname name uni fun ann -> Term tyname name uni fun ann Source #

lamAbs :: ann -> name -> Type tyname uni ann -> Term tyname name uni fun ann -> Term tyname name uni fun ann Source #

apply :: ann -> Term tyname name uni fun ann -> Term tyname name uni fun ann -> Term tyname name uni fun ann Source #

constant :: ann -> Some ( ValueOf uni) -> Term tyname name uni fun ann Source #

builtin :: ann -> fun -> Term tyname name uni fun ann Source #

tyInst :: ann -> Term tyname name uni fun ann -> Type tyname uni ann -> Term tyname name uni fun ann Source #

unwrap :: ann -> Term tyname name uni fun ann -> Term tyname name uni fun ann Source #

iWrap :: ann -> Type tyname uni ann -> Type tyname uni ann -> Term tyname name uni fun ann -> Term tyname name uni fun ann Source #

error :: ann -> Type tyname uni ann -> Term tyname name uni fun ann Source #

termLet :: ann -> TermDef ( Term tyname name uni fun) tyname name uni fun ann -> Term tyname name uni fun ann -> Term tyname name uni fun ann Source #

typeLet :: ann -> TypeDef tyname uni ann -> Term tyname name uni fun ann -> Term tyname name uni fun ann Source #

( GEq uni, Closed uni, Everywhere uni Eq , Eq fun, Eq ann) => Eq ( Term TyName Name uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Eq

( GEq uni, Closed uni, Everywhere uni Eq , Eq fun, Eq ann) => Eq ( Term TyDeBruijn DeBruijn uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Eq

( GEq uni, Closed uni, Everywhere uni Eq , Eq fun, Eq ann) => Eq ( Term NamedTyDeBruijn NamedDeBruijn uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Eq

( Everywhere uni Show , GShow uni, Closed uni, Show ann, Show name, Show tyname, Show fun) => Show ( Term tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Type

Methods

showsPrec :: Int -> Term tyname name uni fun ann -> ShowS Source #

show :: Term tyname name uni fun ann -> String Source #

showList :: [ Term tyname name uni fun ann] -> ShowS Source #

Generic ( Term tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Type

Associated Types

type Rep ( Term tyname name uni fun ann) :: Type -> Type Source #

Methods

from :: Term tyname name uni fun ann -> Rep ( Term tyname name uni fun ann) x Source #

to :: Rep ( Term tyname name uni fun ann) x -> Term tyname name uni fun ann Source #

( Everywhere uni NFData , Closed uni, NFData ann, NFData name, NFData tyname, NFData fun) => NFData ( Term tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Type

Methods

rnf :: Term tyname name uni fun ann -> () Source #

( Closed uni, Everywhere uni Flat , Flat fun, Flat ann, Flat tyname, Flat name) => Flat ( Term tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Flat

Methods

encode :: Term tyname name uni fun ann -> Encoding Source #

decode :: Get ( Term tyname name uni fun ann) Source #

size :: Term tyname name uni fun ann -> NumBits -> NumBits Source #

( PrettyClassic tyname, PrettyClassic name, GShow uni, Closed uni, Everywhere uni PrettyConst , Pretty fun, Pretty ann) => Pretty ( Term tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Pretty.Default

Methods

pretty :: Term tyname name uni fun ann -> Doc ann0 Source #

prettyList :: [ Term tyname name uni fun ann] -> Doc ann0 Source #

Recursive ( Term tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Recursive

Methods

project :: Term tyname name uni fun ann -> Base ( Term tyname name uni fun ann) ( Term tyname name uni fun ann) Source #

cata :: ( Base ( Term tyname name uni fun ann) a -> a) -> Term tyname name uni fun ann -> a Source #

para :: ( Base ( Term tyname name uni fun ann) ( Term tyname name uni fun ann, a) -> a) -> Term tyname name uni fun ann -> a Source #

gpara :: ( Corecursive ( Term tyname name uni fun ann), Comonad w) => ( forall b. Base ( Term tyname name uni fun ann) (w b) -> w ( Base ( Term tyname name uni fun ann) b)) -> ( Base ( Term tyname name uni fun ann) ( EnvT ( Term tyname name uni fun ann) w a) -> a) -> Term tyname name uni fun ann -> a Source #

prepro :: Corecursive ( Term tyname name uni fun ann) => ( forall b. Base ( Term tyname name uni fun ann) b -> Base ( Term tyname name uni fun ann) b) -> ( Base ( Term tyname name uni fun ann) a -> a) -> Term tyname name uni fun ann -> a Source #

gprepro :: ( Corecursive ( Term tyname name uni fun ann), Comonad w) => ( forall b. Base ( Term tyname name uni fun ann) (w b) -> w ( Base ( Term tyname name uni fun ann) b)) -> ( forall c. Base ( Term tyname name uni fun ann) c -> Base ( Term tyname name uni fun ann) c) -> ( Base ( Term tyname name uni fun ann) (w a) -> a) -> Term tyname name uni fun ann -> a Source #

Corecursive ( Term tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Recursive

Methods

embed :: Base ( Term tyname name uni fun ann) ( Term tyname name uni fun ann) -> Term tyname name uni fun ann Source #

ana :: (a -> Base ( Term tyname name uni fun ann) a) -> a -> Term tyname name uni fun ann Source #

apo :: (a -> Base ( Term tyname name uni fun ann) ( Either ( Term tyname name uni fun ann) a)) -> a -> Term tyname name uni fun ann Source #

postpro :: Recursive ( Term tyname name uni fun ann) => ( forall b. Base ( Term tyname name uni fun ann) b -> Base ( Term tyname name uni fun ann) b) -> (a -> Base ( Term tyname name uni fun ann) a) -> a -> Term tyname name uni fun ann Source #

gpostpro :: ( Recursive ( Term tyname name uni fun ann), Monad m) => ( forall b. m ( Base ( Term tyname name uni fun ann) b) -> Base ( Term tyname name uni fun ann) (m b)) -> ( forall c. Base ( Term tyname name uni fun ann) c -> Base ( Term tyname name uni fun ann) c) -> (a -> Base ( Term tyname name uni fun ann) (m a)) -> a -> Term tyname name uni fun ann Source #

HasUniques ( Term tyname name uni fun ann) => Rename ( Term tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Rename

Methods

rename :: MonadQuote m => Term tyname name uni fun ann -> m ( Term tyname name uni fun ann) Source #

HasConstant ( Term TyName Name uni fun ()) Source #
Instance details

Defined in PlutusCore.Builtin.HasConstant

type Rep ( Term tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Type

type Rep ( Term tyname name uni fun ann) = D1 (' MetaData "Term" "PlutusCore.Core.Type" "plutus-core-1.0.0.1-76bWF9ZEWyb4eDyjHx0kCS" ' False ) ((( C1 (' MetaCons "Var" ' PrefixI ' False ) ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ann) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 name)) :+: C1 (' MetaCons "TyAbs" ' PrefixI ' False ) (( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ann) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 tyname)) :*: ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( Kind ann)) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( Term tyname name uni fun ann))))) :+: ( C1 (' MetaCons "LamAbs" ' PrefixI ' False ) (( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ann) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 name)) :*: ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( Type tyname uni ann)) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( Term tyname name uni fun ann)))) :+: ( C1 (' MetaCons "Apply" ' PrefixI ' False ) ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ann) :*: ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( Term tyname name uni fun ann)) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( Term tyname name uni fun ann)))) :+: C1 (' MetaCons "Constant" ' PrefixI ' False ) ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ann) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( Some ( ValueOf uni))))))) :+: (( C1 (' MetaCons "Builtin" ' PrefixI ' False ) ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ann) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 fun)) :+: C1 (' MetaCons "TyInst" ' PrefixI ' False ) ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ann) :*: ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( Term tyname name uni fun ann)) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( Type tyname uni ann))))) :+: ( C1 (' MetaCons "Unwrap" ' PrefixI ' False ) ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ann) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( Term tyname name uni fun ann))) :+: ( C1 (' MetaCons "IWrap" ' PrefixI ' False ) (( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ann) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( Type tyname uni ann))) :*: ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( Type tyname uni ann)) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( Term tyname name uni fun ann)))) :+: C1 (' MetaCons "Error" ' PrefixI ' False ) ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ann) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( Type tyname uni ann)))))))
type Base ( Term tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Recursive

type Base ( Term tyname name uni fun ann) = TermF tyname name uni fun ann
type UniOf ( Term tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Type

type UniOf ( Term tyname name uni fun ann) = uni
type HasUniques ( Term tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Type

type HasUniques ( Term tyname name uni fun ann) = ( HasUnique tyname TypeUnique , HasUnique name TermUnique )

termSubterms :: Traversal' ( Term tyname name uni fun ann) ( Term tyname name uni fun ann) Source #

Get all the direct child Term s of the given Term .

termSubtypes :: Traversal' ( Term tyname name uni fun ann) ( Type tyname uni ann) Source #

Get all the direct child Type s of the given Term .

type family UniOf a :: Type -> Type Source #

Extract the universe from a type.

Instances

Instances details
type UniOf ( Opaque val rep) Source #
Instance details

Defined in PlutusCore.Builtin.Polymorphism

type UniOf ( Opaque val rep) = UniOf val
type UniOf ( CkValue uni fun) Source #
Instance details

Defined in PlutusCore.Evaluation.Machine.Ck

type UniOf ( CkValue uni fun) = uni
type UniOf ( CekValue uni fun) Source #
Instance details

Defined in UntypedPlutusCore.Evaluation.Machine.Cek.Internal

type UniOf ( CekValue uni fun) = uni
type UniOf ( Term name uni fun ann) Source #
Instance details

Defined in UntypedPlutusCore.Core.Type

type UniOf ( Term name uni fun ann) = uni
type UniOf ( Term tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Type

type UniOf ( Term tyname name uni fun ann) = uni
type UniOf ( Term tyname name uni fun ann) Source #
Instance details

Defined in PlutusIR.Core.Type

type UniOf ( Term tyname name uni fun ann) = uni

data Type tyname uni ann Source #

A Type assigned to expressions.

Constructors

TyVar ann tyname
TyFun ann ( Type tyname uni ann) ( Type tyname uni ann)
TyIFix ann ( Type tyname uni ann) ( Type tyname uni ann)

Fix-point type, for constructing self-recursive types

TyForall ann tyname ( Kind ann) ( Type tyname uni ann)
TyBuiltin ann ( SomeTypeIn uni)

Builtin type

TyLam ann tyname ( Kind ann) ( Type tyname uni ann)
TyApp ann ( Type tyname uni ann) ( Type tyname uni ann)

Instances

Instances details
tyname ~ TyName => Reference TyName ( Type tyname uni) Source #
Instance details

Defined in PlutusCore.Core.Instance.Scoping

Methods

referenceVia :: ( forall name. ToScopedName name => name -> NameAnn ) -> TyName -> Type tyname uni NameAnn -> Type tyname uni NameAnn Source #

DefaultPrettyPlcStrategy ( Type tyname uni ann) => PrettyBy PrettyConfigPlc ( Type tyname uni ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Pretty.Plc

( PrettyReadableBy configName tyname, GShow uni) => PrettyBy ( PrettyConfigReadable configName) ( Type tyname uni a) Source #
Instance details

Defined in PlutusCore.Core.Instance.Pretty.Readable

( PrettyClassicBy configName tyname, GShow uni, Pretty ann) => PrettyBy ( PrettyConfigClassic configName) ( Type tyname uni ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Pretty.Classic

Methods

prettyBy :: PrettyConfigClassic configName -> Type tyname uni ann -> Doc ann0 Source #

prettyListBy :: PrettyConfigClassic configName -> [ Type tyname uni ann] -> Doc ann0 Source #

Functor ( Type tyname uni) Source #
Instance details

Defined in PlutusCore.Core.Type

Methods

fmap :: (a -> b) -> Type tyname uni a -> Type tyname uni b Source #

(<$) :: a -> Type tyname uni b -> Type tyname uni a Source #

tyname ~ TyName => CollectScopeInfo ( Type tyname uni) Source #
Instance details

Defined in PlutusCore.Core.Instance.Scoping

tyname ~ TyName => EstablishScoping ( Type tyname uni) Source #
Instance details

Defined in PlutusCore.Core.Instance.Scoping

Methods

establishScoping :: Type tyname uni ann -> Quote ( Type tyname uni NameAnn ) Source #

( GEq uni, Eq ann) => Eq ( Type TyName uni ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Eq

( GEq uni, Closed uni, Everywhere uni Eq , Eq ann) => Eq ( Type TyDeBruijn uni ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Eq

( GEq uni, Closed uni, Everywhere uni Eq , Eq ann) => Eq ( Type NamedTyDeBruijn uni ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Eq

( Show ann, Show tyname, GShow uni) => Show ( Type tyname uni ann) Source #
Instance details

Defined in PlutusCore.Core.Type

Generic ( Type tyname uni ann) Source #
Instance details

Defined in PlutusCore.Core.Type

Associated Types

type Rep ( Type tyname uni ann) :: Type -> Type Source #

Methods

from :: Type tyname uni ann -> Rep ( Type tyname uni ann) x Source #

to :: Rep ( Type tyname uni ann) x -> Type tyname uni ann Source #

( NFData ann, NFData tyname, Closed uni) => NFData ( Type tyname uni ann) Source #
Instance details

Defined in PlutusCore.Core.Type

Methods

rnf :: Type tyname uni ann -> () Source #

( Closed uni, Flat ann, Flat tyname) => Flat ( Type tyname uni ann) Source #
Instance details

Defined in PlutusCore.Flat

( PrettyClassic tyname, GShow uni, Pretty ann) => Pretty ( Type tyname uni ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Pretty.Default

Methods

pretty :: Type tyname uni ann -> Doc ann0 Source #

prettyList :: [ Type tyname uni ann] -> Doc ann0 Source #

Recursive ( Type tyname uni ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Recursive

Methods

project :: Type tyname uni ann -> Base ( Type tyname uni ann) ( Type tyname uni ann) Source #

cata :: ( Base ( Type tyname uni ann) a -> a) -> Type tyname uni ann -> a Source #

para :: ( Base ( Type tyname uni ann) ( Type tyname uni ann, a) -> a) -> Type tyname uni ann -> a Source #

gpara :: ( Corecursive ( Type tyname uni ann), Comonad w) => ( forall b. Base ( Type tyname uni ann) (w b) -> w ( Base ( Type tyname uni ann) b)) -> ( Base ( Type tyname uni ann) ( EnvT ( Type tyname uni ann) w a) -> a) -> Type tyname uni ann -> a Source #

prepro :: Corecursive ( Type tyname uni ann) => ( forall b. Base ( Type tyname uni ann) b -> Base ( Type tyname uni ann) b) -> ( Base ( Type tyname uni ann) a -> a) -> Type tyname uni ann -> a Source #

gprepro :: ( Corecursive ( Type tyname uni ann), Comonad w) => ( forall b. Base ( Type tyname uni ann) (w b) -> w ( Base ( Type tyname uni ann) b)) -> ( forall c. Base ( Type tyname uni ann) c -> Base ( Type tyname uni ann) c) -> ( Base ( Type tyname uni ann) (w a) -> a) -> Type tyname uni ann -> a Source #

Corecursive ( Type tyname uni ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Recursive

Methods

embed :: Base ( Type tyname uni ann) ( Type tyname uni ann) -> Type tyname uni ann Source #

ana :: (a -> Base ( Type tyname uni ann) a) -> a -> Type tyname uni ann Source #

apo :: (a -> Base ( Type tyname uni ann) ( Either ( Type tyname uni ann) a)) -> a -> Type tyname uni ann Source #

postpro :: Recursive ( Type tyname uni ann) => ( forall b. Base ( Type tyname uni ann) b -> Base ( Type tyname uni ann) b) -> (a -> Base ( Type tyname uni ann) a) -> a -> Type tyname uni ann Source #

gpostpro :: ( Recursive ( Type tyname uni ann), Monad m) => ( forall b. m ( Base ( Type tyname uni ann) b) -> Base ( Type tyname uni ann) (m b)) -> ( forall c. Base ( Type tyname uni ann) c -> Base ( Type tyname uni ann) c) -> (a -> Base ( Type tyname uni ann) (m a)) -> a -> Type tyname uni ann Source #

HasUniques ( Type tyname uni ann) => Rename ( Type tyname uni ann) Source #
Instance details

Defined in PlutusCore.Rename

Methods

rename :: MonadQuote m => Type tyname uni ann -> m ( Type tyname uni ann) Source #

type Rep ( Type tyname uni ann) Source #
Instance details

Defined in PlutusCore.Core.Type

type Rep ( Type tyname uni ann) = D1 (' MetaData "Type" "PlutusCore.Core.Type" "plutus-core-1.0.0.1-76bWF9ZEWyb4eDyjHx0kCS" ' False ) (( C1 (' MetaCons "TyVar" ' PrefixI ' False ) ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ann) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 tyname)) :+: ( C1 (' MetaCons "TyFun" ' PrefixI ' False ) ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ann) :*: ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( Type tyname uni ann)) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( Type tyname uni ann)))) :+: C1 (' MetaCons "TyIFix" ' PrefixI ' False ) ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ann) :*: ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( Type tyname uni ann)) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( Type tyname uni ann)))))) :+: (( C1 (' MetaCons "TyForall" ' PrefixI ' False ) (( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ann) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 tyname)) :*: ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( Kind ann)) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( Type tyname uni ann)))) :+: C1 (' MetaCons "TyBuiltin" ' PrefixI ' False ) ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ann) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( SomeTypeIn uni)))) :+: ( C1 (' MetaCons "TyLam" ' PrefixI ' False ) (( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ann) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 tyname)) :*: ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( Kind ann)) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( Type tyname uni ann)))) :+: C1 (' MetaCons "TyApp" ' PrefixI ' False ) ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ann) :*: ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( Type tyname uni ann)) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( Type tyname uni ann)))))))
type Base ( Type tyname uni ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Recursive

type Base ( Type tyname uni ann) = TypeF tyname uni ann
type HasUniques ( Type tyname uni ann) Source #
Instance details

Defined in PlutusCore.Core.Type

type HasUniques ( Type tyname uni ann) = HasUnique tyname TypeUnique

typeSubtypes :: Traversal' ( Type tyname uni ann) ( Type tyname uni ann) Source #

Get all the direct child Type s of the given Type .

data Kind ann Source #

Constructors

Type ann
KindArrow ann ( Kind ann) ( Kind ann)

Instances

Instances details
Functor Kind Source #
Instance details

Defined in PlutusCore.Core.Type

CollectScopeInfo Kind Source #
Instance details

Defined in PlutusCore.Core.Instance.Scoping

EstablishScoping Kind Source #
Instance details

Defined in PlutusCore.Core.Instance.Scoping

Lift ann => Lift ( Kind ann :: Type ) Source #
Instance details

Defined in PlutusCore.Core.Type

DefaultPrettyPlcStrategy ( Kind ann) => PrettyBy PrettyConfigPlc ( Kind ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Pretty.Plc

Eq ann => Eq ( Kind ann) Source #
Instance details

Defined in PlutusCore.Core.Type

Show ann => Show ( Kind ann) Source #
Instance details

Defined in PlutusCore.Core.Type

Generic ( Kind ann) Source #
Instance details

Defined in PlutusCore.Core.Type

Associated Types

type Rep ( Kind ann) :: Type -> Type Source #

Hashable ann => Hashable ( Kind ann) Source #
Instance details

Defined in PlutusCore.Core.Type

NFData ann => NFData ( Kind ann) Source #
Instance details

Defined in PlutusCore.Core.Type

Methods

rnf :: Kind ann -> () Source #

Flat ann => Flat ( Kind ann) Source #
Instance details

Defined in PlutusCore.Flat

Pretty ann => Pretty ( Kind ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Pretty.Default

Recursive ( Kind ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Recursive

Methods

project :: Kind ann -> Base ( Kind ann) ( Kind ann) Source #

cata :: ( Base ( Kind ann) a -> a) -> Kind ann -> a Source #

para :: ( Base ( Kind ann) ( Kind ann, a) -> a) -> Kind ann -> a Source #

gpara :: ( Corecursive ( Kind ann), Comonad w) => ( forall b. Base ( Kind ann) (w b) -> w ( Base ( Kind ann) b)) -> ( Base ( Kind ann) ( EnvT ( Kind ann) w a) -> a) -> Kind ann -> a Source #

prepro :: Corecursive ( Kind ann) => ( forall b. Base ( Kind ann) b -> Base ( Kind ann) b) -> ( Base ( Kind ann) a -> a) -> Kind ann -> a Source #

gprepro :: ( Corecursive ( Kind ann), Comonad w) => ( forall b. Base ( Kind ann) (w b) -> w ( Base ( Kind ann) b)) -> ( forall c. Base ( Kind ann) c -> Base ( Kind ann) c) -> ( Base ( Kind ann) (w a) -> a) -> Kind ann -> a Source #

Corecursive ( Kind ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Recursive

Methods

embed :: Base ( Kind ann) ( Kind ann) -> Kind ann Source #

ana :: (a -> Base ( Kind ann) a) -> a -> Kind ann Source #

apo :: (a -> Base ( Kind ann) ( Either ( Kind ann) a)) -> a -> Kind ann Source #

postpro :: Recursive ( Kind ann) => ( forall b. Base ( Kind ann) b -> Base ( Kind ann) b) -> (a -> Base ( Kind ann) a) -> a -> Kind ann Source #

gpostpro :: ( Recursive ( Kind ann), Monad m) => ( forall b. m ( Base ( Kind ann) b) -> Base ( Kind ann) (m b)) -> ( forall c. Base ( Kind ann) c -> Base ( Kind ann) c) -> (a -> Base ( Kind ann) (m a)) -> a -> Kind ann Source #

PrettyBy ( PrettyConfigReadable configName) ( Kind a) Source #
Instance details

Defined in PlutusCore.Core.Instance.Pretty.Readable

Pretty ann => PrettyBy ( PrettyConfigClassic configName) ( Kind ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Pretty.Classic

type Rep ( Kind ann) Source #
Instance details

Defined in PlutusCore.Core.Type

type Base ( Kind ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Recursive

type Base ( Kind ann) = KindF ann
type HasUniques ( Kind ann) Source #
Instance details

Defined in PlutusCore.Core.Type

type HasUniques ( Kind ann) = ()

data ParseError Source #

An error encountered during parsing.

Instances

Instances details
Eq ParseError Source #
Instance details

Defined in PlutusCore.Error

Ord ParseError Source #
Instance details

Defined in PlutusCore.Error

Show ParseError Source #
Instance details

Defined in PlutusCore.Error

Generic ParseError Source #
Instance details

Defined in PlutusCore.Error

NFData ParseError Source #
Instance details

Defined in PlutusCore.Error

ShowErrorComponent ParseError Source #
Instance details

Defined in PlutusCore.Error

Pretty ParseError Source #
Instance details

Defined in PlutusCore.Error

HasErrorCode ParseError Source #
Instance details

Defined in PlutusCore.Error

AsParseError ParseError Source #
Instance details

Defined in PlutusCore.Error

type Rep ParseError Source #
Instance details

Defined in PlutusCore.Error

data Version ann Source #

Version of Plutus Core to be used for the program.

Instances

Instances details
Functor Version Source #
Instance details

Defined in PlutusCore.Core.Type

Eq ann => Eq ( Version ann) Source #
Instance details

Defined in PlutusCore.Core.Type

Show ann => Show ( Version ann) Source #
Instance details

Defined in PlutusCore.Core.Type

Generic ( Version ann) Source #
Instance details

Defined in PlutusCore.Core.Type

Associated Types

type Rep ( Version ann) :: Type -> Type Source #

Hashable ann => Hashable ( Version ann) Source #
Instance details

Defined in PlutusCore.Core.Type

NFData ann => NFData ( Version ann) Source #
Instance details

Defined in PlutusCore.Core.Type

Methods

rnf :: Version ann -> () Source #

Flat ann => Flat ( Version ann) Source #
Instance details

Defined in PlutusCore.Flat

Pretty ( Version ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Pretty.Common

type Rep ( Version ann) Source #
Instance details

Defined in PlutusCore.Core.Type

data Program tyname name uni fun ann Source #

A Program is simply a Term coupled with a Version of the core language.

Constructors

Program

Fields

Instances

Instances details
DefaultPrettyPlcStrategy ( Program tyname name uni fun ann) => PrettyBy PrettyConfigPlc ( Program tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Pretty.Plc

Methods

prettyBy :: PrettyConfigPlc -> Program tyname name uni fun ann -> Doc ann0 Source #

prettyListBy :: PrettyConfigPlc -> [ Program tyname name uni fun ann] -> Doc ann0 Source #

PrettyReadableBy configName ( Term tyname name uni fun a) => PrettyBy ( PrettyConfigReadable configName) ( Program tyname name uni fun a) Source #
Instance details

Defined in PlutusCore.Core.Instance.Pretty.Readable

Methods

prettyBy :: PrettyConfigReadable configName -> Program tyname name uni fun a -> Doc ann Source #

prettyListBy :: PrettyConfigReadable configName -> [ Program tyname name uni fun a] -> Doc ann Source #

( PrettyClassicBy configName ( Term tyname name uni fun ann), Pretty ann) => PrettyBy ( PrettyConfigClassic configName) ( Program tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Pretty.Classic

Methods

prettyBy :: PrettyConfigClassic configName -> Program tyname name uni fun ann -> Doc ann0 Source #

prettyListBy :: PrettyConfigClassic configName -> [ Program tyname name uni fun ann] -> Doc ann0 Source #

Functor ( Program tyname name uni fun) Source #
Instance details

Defined in PlutusCore.Core.Type

Methods

fmap :: (a -> b) -> Program tyname name uni fun a -> Program tyname name uni fun b Source #

(<$) :: a -> Program tyname name uni fun b -> Program tyname name uni fun a Source #

(tyname ~ TyName , name ~ Name ) => CollectScopeInfo ( Program tyname name uni fun) Source #
Instance details

Defined in PlutusCore.Core.Instance.Scoping

(tyname ~ TyName , name ~ Name ) => EstablishScoping ( Program tyname name uni fun) Source #
Instance details

Defined in PlutusCore.Core.Instance.Scoping

Methods

establishScoping :: Program tyname name uni fun ann -> Quote ( Program tyname name uni fun NameAnn ) Source #

( GEq uni, Closed uni, Everywhere uni Eq , Eq fun, Eq ann, Eq ( Term tyname name uni fun ann)) => Eq ( Program tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Eq

Methods

(==) :: Program tyname name uni fun ann -> Program tyname name uni fun ann -> Bool Source #

(/=) :: Program tyname name uni fun ann -> Program tyname name uni fun ann -> Bool Source #

( Everywhere uni Show , GShow uni, Closed uni, Show ann, Show name, Show tyname, Show fun) => Show ( Program tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Type

Methods

showsPrec :: Int -> Program tyname name uni fun ann -> ShowS Source #

show :: Program tyname name uni fun ann -> String Source #

showList :: [ Program tyname name uni fun ann] -> ShowS Source #

Generic ( Program tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Type

Associated Types

type Rep ( Program tyname name uni fun ann) :: Type -> Type Source #

Methods

from :: Program tyname name uni fun ann -> Rep ( Program tyname name uni fun ann) x Source #

to :: Rep ( Program tyname name uni fun ann) x -> Program tyname name uni fun ann Source #

( Everywhere uni NFData , Closed uni, NFData ann, NFData name, NFData tyname, NFData fun) => NFData ( Program tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Type

Methods

rnf :: Program tyname name uni fun ann -> () Source #

( Flat ann, Flat ( Term tyname name uni fun ann)) => Flat ( Program tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Flat

Methods

encode :: Program tyname name uni fun ann -> Encoding Source #

decode :: Get ( Program tyname name uni fun ann) Source #

size :: Program tyname name uni fun ann -> NumBits -> NumBits Source #

( PrettyClassic tyname, PrettyClassic name, GShow uni, Closed uni, Everywhere uni PrettyConst , Pretty fun, Pretty ann) => Pretty ( Program tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Pretty.Default

Methods

pretty :: Program tyname name uni fun ann -> Doc ann0 Source #

prettyList :: [ Program tyname name uni fun ann] -> Doc ann0 Source #

HasUniques ( Program tyname name uni fun ann) => Rename ( Program tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Rename

Methods

rename :: MonadQuote m => Program tyname name uni fun ann -> m ( Program tyname name uni fun ann) Source #

type Rep ( Program tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Type

type Rep ( Program tyname name uni fun ann) = D1 (' MetaData "Program" "PlutusCore.Core.Type" "plutus-core-1.0.0.1-76bWF9ZEWyb4eDyjHx0kCS" ' False ) ( C1 (' MetaCons "Program" ' PrefixI ' True ) ( S1 (' MetaSel (' Just "_progAnn") ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ann) :*: ( S1 (' MetaSel (' Just "_progVer") ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( Version ann)) :*: S1 (' MetaSel (' Just "_progTerm") ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( Term tyname name uni fun ann)))))
type HasUniques ( Program tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Type

type HasUniques ( Program tyname name uni fun ann) = HasUniques ( Term tyname name uni fun ann)

data Name Source #

A Name represents variables/names in Plutus Core.

Constructors

Name

Fields

Instances

Instances details
Eq Name Source #
Instance details

Defined in PlutusCore.Name

Ord Name Source #
Instance details

Defined in PlutusCore.Name

Show Name Source #
Instance details

Defined in PlutusCore.Name

Generic Name Source #
Instance details

Defined in PlutusCore.Name

Associated Types

type Rep Name :: Type -> Type Source #

Hashable Name Source #
Instance details

Defined in PlutusCore.Name

NFData Name Source #
Instance details

Defined in PlutusCore.Name

Flat Name Source #
Instance details

Defined in PlutusCore.Flat

ToScopedName Name Source #
Instance details

Defined in PlutusCore.Check.Scoping

Lift Name Source #
Instance details

Defined in PlutusCore.Name

HasPrettyConfigName config => PrettyBy config Name Source #
Instance details

Defined in PlutusCore.Name

HasUnique Name TermUnique Source #
Instance details

Defined in PlutusCore.Name

name ~ Name => Reference Name ( Term tyname name uni fun) Source #
Instance details

Defined in PlutusCore.Core.Instance.Scoping

Methods

referenceVia :: ( forall name0. ToScopedName name0 => name0 -> NameAnn ) -> Name -> Term tyname name uni fun NameAnn -> Term tyname name uni fun NameAnn Source #

name ~ Name => Reference Name ( Term tyname name uni fun) Source #
Instance details

Defined in PlutusIR.Core.Instance.Scoping

Methods

referenceVia :: ( forall name0. ToScopedName name0 => name0 -> NameAnn ) -> Name -> Term tyname name uni fun NameAnn -> Term tyname name uni fun NameAnn Source #

name ~ Name => Reference Name ( Binding tyname name uni fun) Source #

Unlike other Reference instances this one does not guarantee that the name will actually be referenced, but it's too convenient to have this instance to give up on it, without it would be awkward to express "reference this binding in this thing".

Instance details

Defined in PlutusIR.Core.Instance.Scoping

Methods

referenceVia :: ( forall name0. ToScopedName name0 => name0 -> NameAnn ) -> Name -> Binding tyname name uni fun NameAnn -> Binding tyname name uni fun NameAnn Source #

Flat ( Binder Name ) Source #
Instance details

Defined in PlutusCore.Flat

AsTypeError ( Error uni fun ann) ( Term TyName Name uni fun ()) uni fun ann Source #
Instance details

Defined in PlutusCore.Error

AsTypeError ( Error uni fun a) ( Term TyName Name uni fun ()) uni fun a Source #
Instance details

Defined in PlutusIR.Error

( GEq uni, Closed uni, Everywhere uni Eq , Eq fun, Eq ann) => Eq ( Term Name uni fun ann) Source #
Instance details

Defined in UntypedPlutusCore.Core.Instance.Eq

( GEq uni, Closed uni, Everywhere uni Eq , Eq fun, Eq ann) => Eq ( Term TyName Name uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Eq

HasConstant ( Term TyName Name uni fun ()) Source #
Instance details

Defined in PlutusCore.Builtin.HasConstant

( Reference TyName t, Reference Name t) => Reference ( Binding TyName Name uni fun ann) t Source #
Instance details

Defined in PlutusIR.Core.Instance.Scoping

Methods

referenceVia :: ( forall name. ToScopedName name => name -> NameAnn ) -> Binding TyName Name uni fun ann -> t NameAnn -> t NameAnn Source #

( Reference TyName t, Reference Name t) => Reference ( Datatype TyName Name uni fun ann) t Source #
Instance details

Defined in PlutusIR.Core.Instance.Scoping

Methods

referenceVia :: ( forall name. ToScopedName name => name -> NameAnn ) -> Datatype TyName Name uni fun ann -> t NameAnn -> t NameAnn Source #

type Rep Name Source #
Instance details

Defined in PlutusCore.Name

newtype TyName Source #

We use a newtype to enforce separation between names used for types and those used for terms.

Constructors

TyName

Instances

Instances details
Eq TyName Source #
Instance details

Defined in PlutusCore.Name

Ord TyName Source #
Instance details

Defined in PlutusCore.Name

Show TyName Source #
Instance details

Defined in PlutusCore.Name

Generic TyName Source #
Instance details

Defined in PlutusCore.Name

Hashable TyName Source #
Instance details

Defined in PlutusCore.Name

NFData TyName Source #
Instance details

Defined in PlutusCore.Name

Flat TyName Source #
Instance details

Defined in PlutusCore.Flat

Wrapped TyName Source #
Instance details

Defined in PlutusCore.Name

ToScopedName TyName Source #
Instance details

Defined in PlutusCore.Check.Scoping

Lift TyName Source #
Instance details

Defined in PlutusCore.Name

HasPrettyConfigName config => PrettyBy config TyName Source #
Instance details

Defined in PlutusCore.Name

HasUnique TyName TypeUnique Source #
Instance details

Defined in PlutusCore.Name

tyname ~ TyName => Reference TyName ( Type tyname uni) Source #
Instance details

Defined in PlutusCore.Core.Instance.Scoping

Methods

referenceVia :: ( forall name. ToScopedName name => name -> NameAnn ) -> TyName -> Type tyname uni NameAnn -> Type tyname uni NameAnn Source #

tyname ~ TyName => Reference TyName ( Term tyname name uni fun) Source #
Instance details

Defined in PlutusCore.Core.Instance.Scoping

Methods

referenceVia :: ( forall name0. ToScopedName name0 => name0 -> NameAnn ) -> TyName -> Term tyname name uni fun NameAnn -> Term tyname name uni fun NameAnn Source #

tyname ~ TyName => Reference TyName ( Term tyname name uni fun) Source #
Instance details

Defined in PlutusIR.Core.Instance.Scoping

Methods

referenceVia :: ( forall name0. ToScopedName name0 => name0 -> NameAnn ) -> TyName -> Term tyname name uni fun NameAnn -> Term tyname name uni fun NameAnn Source #

tyname ~ TyName => Reference TyName ( Binding tyname name uni fun) Source #
Instance details

Defined in PlutusIR.Core.Instance.Scoping

Methods

referenceVia :: ( forall name0. ToScopedName name0 => name0 -> NameAnn ) -> TyName -> Binding tyname name uni fun NameAnn -> Binding tyname name uni fun NameAnn Source #

tyname ~ TyName => Reference TyName ( Datatype tyname name uni fun) Source #

Scoping for data types is hard, so we employ some extra paranoia and reference the provided TyName in the type of every single constructor, and also apply the final head to that TyName .

Instance details

Defined in PlutusIR.Core.Instance.Scoping

Methods

referenceVia :: ( forall name0. ToScopedName name0 => name0 -> NameAnn ) -> TyName -> Datatype tyname name uni fun NameAnn -> Datatype tyname name uni fun NameAnn Source #

tyname ~ TyName => Reference TyName ( VarDecl tyname name uni fun) Source #
Instance details

Defined in PlutusIR.Core.Instance.Scoping

Methods

referenceVia :: ( forall name0. ToScopedName name0 => name0 -> NameAnn ) -> TyName -> VarDecl tyname name uni fun NameAnn -> VarDecl tyname name uni fun NameAnn Source #

Flat ( Binder TyName ) Source #
Instance details

Defined in PlutusCore.Flat

( GEq uni, Eq ann) => Eq ( Type TyName uni ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Eq

TermLike ( Term name uni fun) TyName name uni fun Source #
Instance details

Defined in UntypedPlutusCore.Core.Type

Methods

var :: ann -> name -> Term name uni fun ann Source #

tyAbs :: ann -> TyName -> Kind ann -> Term name uni fun ann -> Term name uni fun ann Source #

lamAbs :: ann -> name -> Type TyName uni ann -> Term name uni fun ann -> Term name uni fun ann Source #

apply :: ann -> Term name uni fun ann -> Term name uni fun ann -> Term name uni fun ann Source #

constant :: ann -> Some ( ValueOf uni) -> Term name uni fun ann Source #

builtin :: ann -> fun -> Term name uni fun ann Source #

tyInst :: ann -> Term name uni fun ann -> Type TyName uni ann -> Term name uni fun ann Source #

unwrap :: ann -> Term name uni fun ann -> Term name uni fun ann Source #

iWrap :: ann -> Type TyName uni ann -> Type TyName uni ann -> Term name uni fun ann -> Term name uni fun ann Source #

error :: ann -> Type TyName uni ann -> Term name uni fun ann Source #

termLet :: ann -> TermDef ( Term name uni fun) TyName name uni fun ann -> Term name uni fun ann -> Term name uni fun ann Source #

typeLet :: ann -> TypeDef TyName uni ann -> Term name uni fun ann -> Term name uni fun ann Source #

AsTypeError ( Error uni fun ann) ( Term TyName Name uni fun ()) uni fun ann Source #
Instance details

Defined in PlutusCore.Error

AsTypeError ( Error uni fun a) ( Term TyName Name uni fun ()) uni fun a Source #
Instance details

Defined in PlutusIR.Error

( GEq uni, Closed uni, Everywhere uni Eq , Eq fun, Eq ann) => Eq ( Term TyName Name uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Eq

HasConstant ( Term TyName Name uni fun ()) Source #
Instance details

Defined in PlutusCore.Builtin.HasConstant

( Reference TyName t, Reference Name t) => Reference ( Binding TyName Name uni fun ann) t Source #
Instance details

Defined in PlutusIR.Core.Instance.Scoping

Methods

referenceVia :: ( forall name. ToScopedName name => name -> NameAnn ) -> Binding TyName Name uni fun ann -> t NameAnn -> t NameAnn Source #

( Reference TyName t, Reference Name t) => Reference ( Datatype TyName Name uni fun ann) t Source #
Instance details

Defined in PlutusIR.Core.Instance.Scoping

Methods

referenceVia :: ( forall name. ToScopedName name => name -> NameAnn ) -> Datatype TyName Name uni fun ann -> t NameAnn -> t NameAnn Source #

type Rep TyName Source #
Instance details

Defined in PlutusCore.Name

type Rep TyName = D1 (' MetaData "TyName" "PlutusCore.Name" "plutus-core-1.0.0.1-76bWF9ZEWyb4eDyjHx0kCS" ' True ) ( C1 (' MetaCons "TyName" ' PrefixI ' True ) ( S1 (' MetaSel (' Just "unTyName") ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 Name )))
type Unwrapped TyName Source #
Instance details

Defined in PlutusCore.Name

newtype Unique Source #

A unique identifier

Constructors

Unique

Instances

Instances details
Enum Unique Source #
Instance details

Defined in PlutusCore.Name

Eq Unique Source #
Instance details

Defined in PlutusCore.Name

Ord Unique Source #
Instance details

Defined in PlutusCore.Name

Show Unique Source #
Instance details

Defined in PlutusCore.Name

Hashable Unique Source #
Instance details

Defined in PlutusCore.Name

NFData Unique Source #
Instance details

Defined in PlutusCore.Name

Flat Unique Source #
Instance details

Defined in PlutusCore.Flat

Pretty Unique Source #
Instance details

Defined in PlutusCore.Name

ExMemoryUsage Unique Source #
Instance details

Defined in PlutusCore.Evaluation.Machine.ExMemory

Lift Unique Source #
Instance details

Defined in PlutusCore.Name

HasUnique Unique Unique Source #
Instance details

Defined in PlutusCore.Name

newtype UniqueMap unique a Source #

A mapping from uniques to values of type a .

Constructors

UniqueMap

newtype Normalized a Source #

Constructors

Normalized

Fields

Instances

Instances details
Functor Normalized Source #
Instance details

Defined in PlutusCore.Core.Type

Applicative Normalized Source #
Instance details

Defined in PlutusCore.Core.Type

Foldable Normalized Source #
Instance details

Defined in PlutusCore.Core.Type

Traversable Normalized Source #
Instance details

Defined in PlutusCore.Core.Type

PrettyBy config a => PrettyBy config ( Normalized a) Source #
Instance details

Defined in PlutusCore.Core.Type

Eq a => Eq ( Normalized a) Source #
Instance details

Defined in PlutusCore.Core.Type

Show a => Show ( Normalized a) Source #
Instance details

Defined in PlutusCore.Core.Type

Generic ( Normalized a) Source #
Instance details

Defined in PlutusCore.Core.Type

Associated Types

type Rep ( Normalized a) :: Type -> Type Source #

NFData a => NFData ( Normalized a) Source #
Instance details

Defined in PlutusCore.Core.Type

Flat a => Flat ( Normalized a) Source #
Instance details

Defined in PlutusCore.Flat

Pretty a => Pretty ( Normalized a) Source #
Instance details

Defined in PlutusCore.Core.Type

Rename a => Rename ( Normalized a) Source #
Instance details

Defined in PlutusCore.Rename

type Rep ( Normalized a) Source #
Instance details

Defined in PlutusCore.Core.Type

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

defaultVersion :: ann -> Version ann Source #

The default version of Plutus Core supported by this library.

termAnn :: Term tyname name uni fun ann -> ann Source #

typeAnn :: Type tyname uni ann -> ann Source #

tyVarDeclAnn :: forall tyname ann. Lens' ( TyVarDecl tyname ann) ann Source #

tyVarDeclName :: forall tyname ann tyname. Lens ( TyVarDecl tyname ann) ( TyVarDecl tyname ann) tyname tyname Source #

tyVarDeclKind :: forall tyname ann. Lens' ( TyVarDecl tyname ann) ( Kind ann) Source #

varDeclAnn :: forall tyname name uni k (fun :: k) ann k (fun :: k). Lens ( VarDecl tyname name uni (fun :: k) ann) ( VarDecl tyname name uni (fun :: k) ann) ann ann Source #

varDeclName :: forall tyname name uni k (fun :: k) ann name k (fun :: k). Lens ( VarDecl tyname name uni (fun :: k) ann) ( VarDecl tyname name uni (fun :: k) ann) name name Source #

varDeclType :: forall tyname name uni k (fun :: k) ann tyname uni k (fun :: k). Lens ( VarDecl tyname name uni (fun :: k) ann) ( VarDecl tyname name uni (fun :: k) ann) ( Type tyname uni ann) ( Type tyname uni ann) Source #

tyDeclAnn :: forall tyname uni ann. Lens' ( TyDecl tyname uni ann) ann Source #

tyDeclType :: forall tyname uni ann tyname uni. Lens ( TyDecl tyname uni ann) ( TyDecl tyname uni ann) ( Type tyname uni ann) ( Type tyname uni ann) Source #

tyDeclKind :: forall tyname uni ann. Lens' ( TyDecl tyname uni ann) ( Kind ann) Source #

progAnn :: forall tyname name uni fun ann. Lens' ( Program tyname name uni fun ann) ann Source #

progVer :: forall tyname name uni fun ann. Lens' ( Program tyname name uni fun ann) ( Version ann) Source #

progTerm :: forall tyname name uni fun ann tyname name uni fun. Lens ( Program tyname name uni fun ann) ( Program tyname name uni fun ann) ( Term tyname name uni fun ann) ( Term tyname name uni fun ann) Source #

mapFun :: (fun -> fun') -> Term tyname name uni fun ann -> Term tyname name uni fun' ann Source #

Map a function over the set of built-in functions.

DeBruijn representation

newtype DeBruijn Source #

A term name as a de Bruijn index, without the name string.

Constructors

DeBruijn

Instances

Instances details
Eq DeBruijn Source #
Instance details

Defined in PlutusCore.DeBruijn.Internal

Show DeBruijn Source #
Instance details

Defined in PlutusCore.DeBruijn.Internal

Generic DeBruijn Source #
Instance details

Defined in PlutusCore.DeBruijn.Internal

NFData DeBruijn Source #
Instance details

Defined in PlutusCore.DeBruijn.Internal

Flat DeBruijn Source #
Instance details

Defined in PlutusCore.Flat

HasIndex DeBruijn Source #
Instance details

Defined in PlutusCore.DeBruijn.Internal

HasPrettyConfigName config => PrettyBy config DeBruijn Source #
Instance details

Defined in PlutusCore.DeBruijn.Internal

Flat ( Binder DeBruijn ) Source #
Instance details

Defined in PlutusCore.Flat

( GEq uni, Closed uni, Everywhere uni Eq , Eq fun, Eq ann) => Eq ( Term DeBruijn uni fun ann) Source #
Instance details

Defined in UntypedPlutusCore.Core.Instance.Eq

( GEq uni, Closed uni, Everywhere uni Eq , Eq fun, Eq ann) => Eq ( Term TyDeBruijn DeBruijn uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Eq

type Rep DeBruijn Source #
Instance details

Defined in PlutusCore.DeBruijn.Internal

type Rep DeBruijn = D1 (' MetaData "DeBruijn" "PlutusCore.DeBruijn.Internal" "plutus-core-1.0.0.1-76bWF9ZEWyb4eDyjHx0kCS" ' True ) ( C1 (' MetaCons "DeBruijn" ' PrefixI ' True ) ( S1 (' MetaSel (' Just "dbnIndex") ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 Index )))

data NamedDeBruijn Source #

A term name as a de Bruijn index.

Instances

Instances details
Eq NamedDeBruijn Source #
Instance details

Defined in PlutusCore.DeBruijn.Internal

Show NamedDeBruijn Source #
Instance details

Defined in PlutusCore.DeBruijn.Internal

Generic NamedDeBruijn Source #
Instance details

Defined in PlutusCore.DeBruijn.Internal

NFData NamedDeBruijn Source #
Instance details

Defined in PlutusCore.DeBruijn.Internal

Flat NamedDeBruijn Source #
Instance details

Defined in PlutusCore.Flat

HasIndex NamedDeBruijn Source #
Instance details

Defined in PlutusCore.DeBruijn.Internal

HasPrettyConfigName config => PrettyBy config NamedDeBruijn Source #
Instance details

Defined in PlutusCore.DeBruijn.Internal

Flat ( Binder NamedDeBruijn ) Source #
Instance details

Defined in PlutusCore.Flat

PrettyUni uni fun => MonadError ( CekEvaluationException NamedDeBruijn uni fun) ( CekM uni fun s) Source #
Instance details

Defined in UntypedPlutusCore.Evaluation.Machine.Cek.Internal

( GEq uni, Closed uni, Everywhere uni Eq , Eq fun, Eq ann) => Eq ( Term NamedDeBruijn uni fun ann) Source #
Instance details

Defined in UntypedPlutusCore.Core.Instance.Eq

( GEq uni, Closed uni, Everywhere uni Eq , Eq fun, Eq ann) => Eq ( Term NamedTyDeBruijn NamedDeBruijn uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Eq

type Rep NamedDeBruijn Source #
Instance details

Defined in PlutusCore.DeBruijn.Internal

type Rep NamedDeBruijn = D1 (' MetaData "NamedDeBruijn" "PlutusCore.DeBruijn.Internal" "plutus-core-1.0.0.1-76bWF9ZEWyb4eDyjHx0kCS" ' False ) ( C1 (' MetaCons "NamedDeBruijn" ' PrefixI ' True ) ( S1 (' MetaSel (' Just "ndbnString") ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 Text ) :*: S1 (' MetaSel (' Just "ndbnIndex") ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 Index )))

deBruijnTerm :: ( AsFreeVariableError e, MonadError e m) => Term TyName Name uni fun ann -> m ( Term NamedTyDeBruijn NamedDeBruijn uni fun ann) Source #

Convert a Term with TyName s and Name s into a Term with NamedTyDeBruijn s and NamedDeBruijn s. Will throw an error if a free variable is encountered.

unDeBruijnTerm :: ( MonadQuote m, AsFreeVariableError e, MonadError e m) => Term NamedTyDeBruijn NamedDeBruijn uni fun ann -> m ( Term TyName Name uni fun ann) Source #

Convert a Term with NamedTyDeBruijn s and NamedDeBruijn s into a Term with TyName s and Name s. Will throw an error if a free variable is encountered.

Lexer

data SourcePos Source #

The data type SourcePos represents source positions. It contains the name of the source file, a line number, and a column number. Source line and column positions change intensively during parsing, so we need to make them strict to avoid memory leaks.

Instances

Instances details
Eq SourcePos
Instance details

Defined in Text.Megaparsec.Pos

Data SourcePos
Instance details

Defined in Text.Megaparsec.Pos

Methods

gfoldl :: ( forall d b. Data d => c (d -> b) -> d -> c b) -> ( forall g. g -> c g) -> SourcePos -> c SourcePos Source #

gunfold :: ( forall b r. Data b => c (b -> r) -> c r) -> ( forall r. r -> c r) -> Constr -> c SourcePos Source #

toConstr :: SourcePos -> Constr Source #

dataTypeOf :: SourcePos -> DataType Source #

dataCast1 :: Typeable t => ( forall d. Data d => c (t d)) -> Maybe (c SourcePos ) Source #

dataCast2 :: Typeable t => ( forall d e. ( Data d, Data e) => c (t d e)) -> Maybe (c SourcePos ) Source #

gmapT :: ( forall b. Data b => b -> b) -> SourcePos -> SourcePos Source #

gmapQl :: (r -> r' -> r) -> r -> ( forall d. Data d => d -> r') -> SourcePos -> r Source #

gmapQr :: forall r r'. (r' -> r -> r) -> r -> ( forall d. Data d => d -> r') -> SourcePos -> r Source #

gmapQ :: ( forall d. Data d => d -> u) -> SourcePos -> [u] Source #

gmapQi :: Int -> ( forall d. Data d => d -> u) -> SourcePos -> u Source #

gmapM :: Monad m => ( forall d. Data d => d -> m d) -> SourcePos -> m SourcePos Source #

gmapMp :: MonadPlus m => ( forall d. Data d => d -> m d) -> SourcePos -> m SourcePos Source #

gmapMo :: MonadPlus m => ( forall d. Data d => d -> m d) -> SourcePos -> m SourcePos Source #

Ord SourcePos
Instance details

Defined in Text.Megaparsec.Pos

Read SourcePos
Instance details

Defined in Text.Megaparsec.Pos

Show SourcePos
Instance details

Defined in Text.Megaparsec.Pos

Generic SourcePos
Instance details

Defined in Text.Megaparsec.Pos

NFData SourcePos
Instance details

Defined in Text.Megaparsec.Pos

Pretty SourcePos Source #
Instance details

Defined in PlutusCore.Error

type Rep SourcePos
Instance details

Defined in Text.Megaparsec.Pos

Formatting

Processing

type family HasUniques a :: Constraint Source #

All kinds of uniques an entity contains.

Instances

Instances details
type HasUniques ( Kind ann) Source #
Instance details

Defined in PlutusCore.Core.Type

type HasUniques ( Kind ann) = ()
type HasUniques ( Type tyname uni ann) Source #
Instance details

Defined in PlutusCore.Core.Type

type HasUniques ( Type tyname uni ann) = HasUnique tyname TypeUnique
type HasUniques ( Program name uni fun ann) Source #
Instance details

Defined in UntypedPlutusCore.Core.Type

type HasUniques ( Program name uni fun ann) = HasUniques ( Term name uni fun ann)
type HasUniques ( Term name uni fun ann) Source #
Instance details

Defined in UntypedPlutusCore.Core.Type

type HasUniques ( Term name uni fun ann) = HasUnique name TermUnique
type HasUniques ( Program tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Type

type HasUniques ( Program tyname name uni fun ann) = HasUniques ( Term tyname name uni fun ann)
type HasUniques ( Term tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Type

type HasUniques ( Term tyname name uni fun ann) = ( HasUnique tyname TypeUnique , HasUnique name TermUnique )
type HasUniques ( Program tyname name uni fun ann) Source #
Instance details

Defined in PlutusIR.Core.Type

type HasUniques ( Program tyname name uni fun ann) = HasUniques ( Term tyname name uni fun ann)
type HasUniques ( Term tyname name uni fun ann) Source #
Instance details

Defined in PlutusIR.Core.Type

type HasUniques ( Term tyname name uni fun ann) = ( HasUnique tyname TypeUnique , HasUnique name TermUnique )

class Rename a where Source #

The class of things that can be renamed. I.e. things that are capable of satisfying the global uniqueness condition.

Methods

rename :: MonadQuote m => a -> m a Source #

Rename Unique s so that they're globally unique. In case there are any free variables, they must be left untouched and bound variables must not get renamed to free ones. Must always assign new names to bound variables, so that rename can be used for alpha-renaming as well.

Instances

Instances details
Rename a => Rename ( Normalized a) Source #
Instance details

Defined in PlutusCore.Rename

HasUniques ( Type tyname uni ann) => Rename ( Type tyname uni ann) Source #
Instance details

Defined in PlutusCore.Rename

Methods

rename :: MonadQuote m => Type tyname uni ann -> m ( Type tyname uni ann) Source #

HasUniques ( Program name uni fun ann) => Rename ( Program name uni fun ann) Source #
Instance details

Defined in UntypedPlutusCore.Rename

Methods

rename :: MonadQuote m => Program name uni fun ann -> m ( Program name uni fun ann) Source #

HasUniques ( Term name uni fun ann) => Rename ( Term name uni fun ann) Source #
Instance details

Defined in UntypedPlutusCore.Rename

Methods

rename :: MonadQuote m => Term name uni fun ann -> m ( Term name uni fun ann) Source #

HasUniques ( Program tyname name uni fun ann) => Rename ( Program tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Rename

Methods

rename :: MonadQuote m => Program tyname name uni fun ann -> m ( Program tyname name uni fun ann) Source #

HasUniques ( Term tyname name uni fun ann) => Rename ( Term tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Rename

Methods

rename :: MonadQuote m => Term tyname name uni fun ann -> m ( Term tyname name uni fun ann) Source #

HasUniques ( Term tyname name uni fun ann) => Rename ( Program tyname name uni fun ann) Source #
Instance details

Defined in PlutusIR.Transform.Rename

Methods

rename :: MonadQuote m => Program tyname name uni fun ann -> m ( Program tyname name uni fun ann) Source #

HasUniques ( Term tyname name uni fun ann) => Rename ( Term tyname name uni fun ann) Source #
Instance details

Defined in PlutusIR.Transform.Rename

Methods

rename :: MonadQuote m => Term tyname name uni fun ann -> m ( Term tyname name uni fun ann) Source #

Type checking

class ToKind (uni :: Type -> Type ) Source #

For computing the Plutus kind of a built-in type. See kindOfBuiltinType .

Minimal complete definition

toSingKind

Instances

Instances details
ToKind DefaultUni Source #
Instance details

Defined in PlutusCore.Default.Universe

Methods

toSingKind :: forall k (a :: k). DefaultUni ( Esc a) -> SingKind k Source #

Configuration.

newtype TypeCheckConfig uni fun Source #

Configuration of the type checker.

tccBuiltinTypes :: HasTypeCheckConfig c uni fun => Lens' c ( BuiltinTypes uni fun) Source #

builtinMeaningsToTypes :: ( MonadError err m, AsTypeError err term uni fun ann, Typecheckable uni fun) => ann -> m ( BuiltinTypes uni fun) Source #

Extract the TypeScheme from a BuiltinMeaning and convert it to the corresponding Type for each built-in function.

getDefTypeCheckConfig :: ( MonadError err m, AsTypeError err term uni fun ann, Typecheckable uni fun) => ann -> m ( TypeCheckConfig uni fun) Source #

Get the default type checking config.

Kind type inference checking.

inferKind :: ( MonadQuote m, MonadError err m, AsTypeError err term uni fun ann, ToKind uni) => TypeCheckConfig uni fun -> Type TyName uni ann -> m ( Kind ()) Source #

Infer the kind of a type.

checkKind :: ( MonadQuote m, MonadError err m, AsTypeError err term uni fun ann, ToKind uni) => TypeCheckConfig uni fun -> ann -> Type TyName uni ann -> Kind () -> m () Source #

Check a type against a kind. Infers the kind of the type and checks that it's equal to the given kind throwing a TypeError (annotated with the value of the ann argument) otherwise.

inferType :: ( MonadError err m, MonadQuote m, AsTypeError err ( Term TyName Name uni fun ()) uni fun ann, ToKind uni, HasUniApply uni, GEq uni, Ix fun) => TypeCheckConfig uni fun -> Term TyName Name uni fun ann -> m ( Normalized ( Type TyName uni ())) Source #

Infer the type of a term.

checkType :: ( MonadError err m, MonadQuote m, AsTypeError err ( Term TyName Name uni fun ()) uni fun ann, ToKind uni, HasUniApply uni, GEq uni, Ix fun) => TypeCheckConfig uni fun -> ann -> Term TyName Name uni fun ann -> Normalized ( Type TyName uni ()) -> m () Source #

Check a term against a type. Infers the type of the term and checks that it's equal to the given type throwing a TypeError (annotated with the value of the ann argument) otherwise.

checkTypeOfProgram :: ( MonadError err m, MonadQuote m, AsTypeError err ( Term TyName Name uni fun ()) uni fun ann, ToKind uni, HasUniApply uni, GEq uni, Ix fun) => TypeCheckConfig uni fun -> ann -> Program TyName Name uni fun ann -> Normalized ( Type TyName uni ()) -> m () Source #

Check a program against a type. Infers the type of the program and checks that it's equal to the given type throwing a TypeError (annotated with the value of the ann argument) otherwise.

normalizeTypesIn :: ( HasUnique tyname TypeUnique , HasUnique name TermUnique , MonadQuote m, HasUniApply uni) => Term tyname name uni fun ann -> m ( Term tyname name uni fun ann) Source #

Normalize every Type in a Term .

normalizeTypesInProgram :: ( HasUnique tyname TypeUnique , HasUnique name TermUnique , MonadQuote m, HasUniApply uni) => Program tyname name uni fun ann -> m ( Program tyname name uni fun ann) Source #

Normalize every Type in a Program .

class AsTypeError r term uni fun ann | r -> term uni fun ann where Source #

Minimal complete definition

_TypeError

Instances

Instances details
AsTypeError ( Error uni fun ann) ( Term TyName Name uni fun ()) uni fun ann Source #
Instance details

Defined in PlutusCore.Error

AsTypeError ( Error uni fun a) ( Term TyName Name uni fun ()) uni fun a Source #
Instance details

Defined in PlutusIR.Error

AsTypeError ( TypeError term uni fun ann) term uni fun ann Source #
Instance details

Defined in PlutusCore.Error

data TypeError term uni fun ann Source #

Instances

Instances details
( GShow uni, Closed uni, Everywhere uni PrettyConst , Pretty ann, Pretty fun, Pretty term) => PrettyBy PrettyConfigPlc ( TypeError term uni fun ann) Source #
Instance details

Defined in PlutusCore.Error

Functor ( TypeError term uni fun) Source #
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 #

( GEq uni, Eq ann, Eq term, Eq fun) => Eq ( TypeError term uni fun ann) Source #
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 #

( GShow uni, Show ann, Show term, Show fun) => Show ( TypeError term uni fun ann) Source #
Instance details

Defined in PlutusCore.Error

Generic ( TypeError term uni fun ann) Source #
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 #

( Closed uni, NFData ann, NFData term, NFData fun) => NFData ( TypeError term uni fun ann) Source #
Instance details

Defined in PlutusCore.Error

Methods

rnf :: TypeError term uni fun ann -> () Source #

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

Defined in PlutusCore.Error

AsTypeError ( TypeError term uni fun ann) term uni fun ann Source #
Instance details

Defined in PlutusCore.Error

type Rep ( TypeError term uni fun ann) Source #
Instance details

Defined in PlutusCore.Error

type Rep ( TypeError term uni fun ann) = D1 (' MetaData "TypeError" "PlutusCore.Error" "plutus-core-1.0.0.1-76bWF9ZEWyb4eDyjHx0kCS" ' False ) (( C1 (' MetaCons "KindMismatch" ' PrefixI ' False ) (( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ann) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( Type TyName uni ()))) :*: ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( Kind ())) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( Kind ())))) :+: C1 (' MetaCons "TypeMismatch" ' PrefixI ' False ) (( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ann) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 term)) :*: ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( Type TyName uni ())) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( Normalized ( Type TyName uni ())))))) :+: ( C1 (' MetaCons "FreeTypeVariableE" ' PrefixI ' False ) ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ann) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 TyName )) :+: ( C1 (' MetaCons "FreeVariableE" ' PrefixI ' False ) ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ann) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 Name )) :+: C1 (' MetaCons "UnknownBuiltinFunctionE" ' PrefixI ' False ) ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ann) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 fun)))))

Errors

data Error uni fun ann Source #

Instances

Instances details
( GShow uni, Closed uni, Everywhere uni PrettyConst , Pretty fun, Pretty ann) => PrettyBy PrettyConfigPlc ( Error uni fun ann) Source #
Instance details

Defined in PlutusCore.Error

Functor ( Error uni fun) Source #
Instance details

Defined in PlutusCore.Error

Methods

fmap :: (a -> b) -> Error uni fun a -> Error uni fun b Source #

(<$) :: a -> Error uni fun b -> Error uni fun a Source #

( Everywhere uni Eq , GEq uni, Closed uni, Eq ann, Eq fun) => Eq ( Error uni fun ann) Source #
Instance details

Defined in PlutusCore.Error

Methods

(==) :: Error uni fun ann -> Error uni fun ann -> Bool Source #

(/=) :: Error uni fun ann -> Error uni fun ann -> Bool Source #

( Show fun, Show ann, Closed uni, Everywhere uni Show , GShow uni, Show ParseError ) => Show ( Error uni fun ann) Source #
Instance details

Defined in PlutusCore.Error

Generic ( Error uni fun ann) Source #
Instance details

Defined in PlutusCore.Error

Associated Types

type Rep ( Error uni fun ann) :: Type -> Type Source #

Methods

from :: Error uni fun ann -> Rep ( Error uni fun ann) x Source #

to :: Rep ( Error uni fun ann) x -> Error uni fun ann Source #

( Everywhere uni NFData , Closed uni, NFData ann, NFData fun) => NFData ( Error uni fun ann) Source #
Instance details

Defined in PlutusCore.Error

Methods

rnf :: Error uni fun ann -> () Source #

HasErrorCode ( Error _a _b _c) Source #
Instance details

Defined in PlutusCore.Error

AsFreeVariableError ( Error uni fun ann) Source #
Instance details

Defined in PlutusCore.Error

AsParseError ( Error uni fun ann) Source #
Instance details

Defined in PlutusCore.Error

AsUniqueError ( Error uni fun ann) ann Source #
Instance details

Defined in PlutusCore.Error

AsError ( Error uni fun ann) uni fun ann Source #
Instance details

Defined in PlutusCore.Error

(tyname ~ TyName , name ~ Name ) => AsNormCheckError ( Error uni fun ann) tyname name uni fun ann Source #
Instance details

Defined in PlutusCore.Error

Methods

_NormCheckError :: Prism' ( Error uni fun ann) ( NormCheckError tyname name uni fun ann) Source #

_BadType :: Prism' ( Error uni fun ann) (ann, Type tyname uni ann, Text ) Source #

_BadTerm :: Prism' ( Error uni fun ann) (ann, Term tyname name uni fun ann, Text ) Source #

AsTypeError ( Error uni fun ann) ( Term TyName Name uni fun ()) uni fun ann Source #
Instance details

Defined in PlutusCore.Error

type Rep ( Error uni fun ann) Source #
Instance details

Defined in PlutusCore.Error

data NormCheckError tyname name uni fun ann Source #

Constructors

BadType ann ( Type tyname uni ann) Text
BadTerm ann ( Term tyname name uni fun ann) Text

Instances

Instances details
( Pretty ann, PrettyBy config ( Type tyname uni ann), PrettyBy config ( Term tyname name uni fun ann)) => PrettyBy config ( NormCheckError tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Error

Methods

prettyBy :: config -> NormCheckError tyname name uni fun ann -> Doc ann0 Source #

prettyListBy :: config -> [ NormCheckError tyname name uni fun ann] -> Doc ann0 Source #

Functor ( NormCheckError tyname name uni fun) Source #
Instance details

Defined in PlutusCore.Error

Methods

fmap :: (a -> b) -> NormCheckError tyname name uni fun a -> NormCheckError tyname name uni fun b Source #

(<$) :: a -> NormCheckError tyname name uni fun b -> NormCheckError tyname name uni fun a Source #

( Eq ( Term tyname name uni fun ann), Eq ( Type tyname uni ann), GEq uni, Closed uni, Everywhere uni Eq , Eq fun, Eq ann) => Eq ( NormCheckError tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Error

Methods

(==) :: NormCheckError tyname name uni fun ann -> NormCheckError tyname name uni fun ann -> Bool Source #

(/=) :: NormCheckError tyname name uni fun ann -> NormCheckError tyname name uni fun ann -> Bool Source #

( Everywhere uni Show , GShow uni, Closed uni, Show ann, Show tyname, Show name, Show fun) => Show ( NormCheckError tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Error

Generic ( NormCheckError tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Error

Associated Types

type Rep ( NormCheckError tyname name uni fun ann) :: Type -> Type Source #

Methods

from :: NormCheckError tyname name uni fun ann -> Rep ( NormCheckError tyname name uni fun ann) x Source #

to :: Rep ( NormCheckError tyname name uni fun ann) x -> NormCheckError tyname name uni fun ann Source #

( Everywhere uni NFData , Closed uni, NFData ann, NFData tyname, NFData name, NFData fun) => NFData ( NormCheckError tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Error

Methods

rnf :: NormCheckError tyname name uni fun ann -> () Source #

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

Defined in PlutusCore.Error

AsNormCheckError ( NormCheckError tyname name uni fun ann) tyname name uni fun ann Source #
Instance details

Defined in PlutusCore.Error

Methods

_NormCheckError :: Prism' ( NormCheckError tyname name uni fun ann) ( NormCheckError tyname name uni fun ann) Source #

_BadType :: Prism' ( NormCheckError tyname name uni fun ann) (ann, Type tyname uni ann, Text ) Source #

_BadTerm :: Prism' ( NormCheckError tyname name uni fun ann) (ann, Term tyname name uni fun ann, Text ) Source #

type Rep ( NormCheckError tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Error

class AsNormCheckError r tyname name uni fun ann | r -> tyname name uni fun ann where Source #

Minimal complete definition

_NormCheckError

Methods

_NormCheckError :: Prism' r ( NormCheckError tyname name uni fun ann) Source #

_BadType :: Prism' r (ann, Type tyname uni ann, Text ) Source #

_BadTerm :: Prism' r (ann, Term tyname name uni fun ann, Text ) Source #

Instances

Instances details
(tyname ~ TyName , name ~ Name ) => AsNormCheckError ( Error uni fun ann) tyname name uni fun ann Source #
Instance details

Defined in PlutusCore.Error

Methods

_NormCheckError :: Prism' ( Error uni fun ann) ( NormCheckError tyname name uni fun ann) Source #

_BadType :: Prism' ( Error uni fun ann) (ann, Type tyname uni ann, Text ) Source #

_BadTerm :: Prism' ( Error uni fun ann) (ann, Term tyname name uni fun ann, Text ) Source #

AsNormCheckError ( NormCheckError tyname name uni fun ann) tyname name uni fun ann Source #
Instance details

Defined in PlutusCore.Error

Methods

_NormCheckError :: Prism' ( NormCheckError tyname name uni fun ann) ( NormCheckError tyname name uni fun ann) Source #

_BadType :: Prism' ( NormCheckError tyname name uni fun ann) (ann, Type tyname uni ann, Text ) Source #

_BadTerm :: Prism' ( NormCheckError tyname name uni fun ann) (ann, Term tyname name uni fun ann, Text ) Source #

data UniqueError ann Source #

Instances

Instances details
Functor UniqueError Source #
Instance details

Defined in PlutusCore.Error

Eq ann => Eq ( UniqueError ann) Source #
Instance details

Defined in PlutusCore.Error

Show ann => Show ( UniqueError ann) Source #
Instance details

Defined in PlutusCore.Error

Generic ( UniqueError ann) Source #
Instance details

Defined in PlutusCore.Error

Associated Types

type Rep ( UniqueError ann) :: Type -> Type Source #

NFData ann => NFData ( UniqueError ann) Source #
Instance details

Defined in PlutusCore.Error

Pretty ann => Pretty ( UniqueError ann) Source #
Instance details

Defined in PlutusCore.Error

HasErrorCode ( UniqueError _a) Source #
Instance details

Defined in PlutusCore.Error

AsUniqueError ( UniqueError ann) ann Source #
Instance details

Defined in PlutusCore.Error

type Rep ( UniqueError ann) Source #
Instance details

Defined in PlutusCore.Error

data FreeVariableError Source #

We cannot do a correct translation to or from de Bruijn indices if the program is not well-scoped. So we throw an error in such a case.

Instances

Instances details
Eq FreeVariableError Source #
Instance details

Defined in PlutusCore.DeBruijn.Internal

Ord FreeVariableError Source #
Instance details

Defined in PlutusCore.DeBruijn.Internal

Show FreeVariableError Source #
Instance details

Defined in PlutusCore.DeBruijn.Internal

Generic FreeVariableError Source #
Instance details

Defined in PlutusCore.DeBruijn.Internal

Exception FreeVariableError Source #
Instance details

Defined in PlutusCore.DeBruijn.Internal

NFData FreeVariableError Source #
Instance details

Defined in PlutusCore.DeBruijn.Internal

Pretty FreeVariableError Source #
Instance details

Defined in PlutusCore.DeBruijn.Internal

HasErrorCode FreeVariableError Source #
Instance details

Defined in PlutusCore.DeBruijn.Internal

AsFreeVariableError FreeVariableError Source #
Instance details

Defined in PlutusCore.DeBruijn.Internal

type Rep FreeVariableError Source #
Instance details

Defined in PlutusCore.DeBruijn.Internal

Base functors

data TermF (tyname :: Type ) (name :: Type ) (uni :: Type -> Type ) (fun :: Type ) (ann :: Type ) r Source #

Constructors

VarF ann name
TyAbsF ann tyname ( Kind ann) r
LamAbsF ann name ( Type tyname uni ann) r
ApplyF ann r r
ConstantF ann ( Some ( ValueOf uni))
BuiltinF ann fun
TyInstF ann r ( Type tyname uni ann)
UnwrapF ann r
IWrapF ann ( Type tyname uni ann) ( Type tyname uni ann) r
ErrorF ann ( Type tyname uni ann)

Instances

Instances details
Functor ( TermF tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Recursive

Methods

fmap :: (a -> b) -> TermF tyname name uni fun ann a -> TermF tyname name uni fun ann b Source #

(<$) :: a -> TermF tyname name uni fun ann b -> TermF tyname name uni fun ann a Source #

Foldable ( TermF tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Recursive

Methods

fold :: Monoid m => TermF tyname name uni fun ann m -> m Source #

foldMap :: Monoid m => (a -> m) -> TermF tyname name uni fun ann a -> m Source #

foldMap' :: Monoid m => (a -> m) -> TermF tyname name uni fun ann a -> m Source #

foldr :: (a -> b -> b) -> b -> TermF tyname name uni fun ann a -> b Source #

foldr' :: (a -> b -> b) -> b -> TermF tyname name uni fun ann a -> b Source #

foldl :: (b -> a -> b) -> b -> TermF tyname name uni fun ann a -> b Source #

foldl' :: (b -> a -> b) -> b -> TermF tyname name uni fun ann a -> b Source #

foldr1 :: (a -> a -> a) -> TermF tyname name uni fun ann a -> a Source #

foldl1 :: (a -> a -> a) -> TermF tyname name uni fun ann a -> a Source #

toList :: TermF tyname name uni fun ann a -> [a] Source #

null :: TermF tyname name uni fun ann a -> Bool Source #

length :: TermF tyname name uni fun ann a -> Int Source #

elem :: Eq a => a -> TermF tyname name uni fun ann a -> Bool Source #

maximum :: Ord a => TermF tyname name uni fun ann a -> a Source #

minimum :: Ord a => TermF tyname name uni fun ann a -> a Source #

sum :: Num a => TermF tyname name uni fun ann a -> a Source #

product :: Num a => TermF tyname name uni fun ann a -> a Source #

Traversable ( TermF tyname name uni fun ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Recursive

Methods

traverse :: Applicative f => (a -> f b) -> TermF tyname name uni fun ann a -> f ( TermF tyname name uni fun ann b) Source #

sequenceA :: Applicative f => TermF tyname name uni fun ann (f a) -> f ( TermF tyname name uni fun ann a) Source #

mapM :: Monad m => (a -> m b) -> TermF tyname name uni fun ann a -> m ( TermF tyname name uni fun ann b) Source #

sequence :: Monad m => TermF tyname name uni fun ann (m a) -> m ( TermF tyname name uni fun ann a) Source #

data TypeF (tyname :: Type ) (uni :: Type -> Type ) (ann :: Type ) r Source #

Constructors

TyVarF ann tyname
TyFunF ann r r
TyIFixF ann r r
TyForallF ann tyname ( Kind ann) r
TyBuiltinF ann ( SomeTypeIn uni)
TyLamF ann tyname ( Kind ann) r
TyAppF ann r r

Instances

Instances details
Functor ( TypeF tyname uni ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Recursive

Methods

fmap :: (a -> b) -> TypeF tyname uni ann a -> TypeF tyname uni ann b Source #

(<$) :: a -> TypeF tyname uni ann b -> TypeF tyname uni ann a Source #

Foldable ( TypeF tyname uni ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Recursive

Methods

fold :: Monoid m => TypeF tyname uni ann m -> m Source #

foldMap :: Monoid m => (a -> m) -> TypeF tyname uni ann a -> m Source #

foldMap' :: Monoid m => (a -> m) -> TypeF tyname uni ann a -> m Source #

foldr :: (a -> b -> b) -> b -> TypeF tyname uni ann a -> b Source #

foldr' :: (a -> b -> b) -> b -> TypeF tyname uni ann a -> b Source #

foldl :: (b -> a -> b) -> b -> TypeF tyname uni ann a -> b Source #

foldl' :: (b -> a -> b) -> b -> TypeF tyname uni ann a -> b Source #

foldr1 :: (a -> a -> a) -> TypeF tyname uni ann a -> a Source #

foldl1 :: (a -> a -> a) -> TypeF tyname uni ann a -> a Source #

toList :: TypeF tyname uni ann a -> [a] Source #

null :: TypeF tyname uni ann a -> Bool Source #

length :: TypeF tyname uni ann a -> Int Source #

elem :: Eq a => a -> TypeF tyname uni ann a -> Bool Source #

maximum :: Ord a => TypeF tyname uni ann a -> a Source #

minimum :: Ord a => TypeF tyname uni ann a -> a Source #

sum :: Num a => TypeF tyname uni ann a -> a Source #

product :: Num a => TypeF tyname uni ann a -> a Source #

Traversable ( TypeF tyname uni ann) Source #
Instance details

Defined in PlutusCore.Core.Instance.Recursive

Methods

traverse :: Applicative f => (a -> f b) -> TypeF tyname uni ann a -> f ( TypeF tyname uni ann b) Source #

sequenceA :: Applicative f => TypeF tyname uni ann (f a) -> f ( TypeF tyname uni ann a) Source #

mapM :: Monad m => (a -> m b) -> TypeF tyname uni ann a -> m ( TypeF tyname uni ann b) Source #

sequence :: Monad m => TypeF tyname uni ann (m a) -> m ( TypeF tyname uni ann a) Source #

Quotation and term construction

type Quote = QuoteT Identity Source #

A non-transformer version of QuoteT .

data QuoteT m a Source #

The "quotation" monad transformer. Within this monad you can do safe construction of PLC terms using quasiquotation, fresh-name generation, and parsing.

Instances

Instances details
MonadTrans QuoteT Source #
Instance details

Defined in PlutusCore.Quote

Methods

lift :: Monad m => m a -> QuoteT m a Source #

MonadReader r m => MonadReader r ( QuoteT m) Source #
Instance details

Defined in PlutusCore.Quote

MonadState s m => MonadState s ( QuoteT m) Source #
Instance details

Defined in PlutusCore.Quote

MonadError e m => MonadError e ( QuoteT m) Source #
Instance details

Defined in PlutusCore.Quote

MonadWriter w m => MonadWriter w ( QuoteT m) Source #
Instance details

Defined in PlutusCore.Quote

Monad m => Monad ( QuoteT m) Source #
Instance details

Defined in PlutusCore.Quote

Functor m => Functor ( QuoteT m) Source #
Instance details

Defined in PlutusCore.Quote

Methods

fmap :: (a -> b) -> QuoteT m a -> QuoteT m b Source #

(<$) :: a -> QuoteT m b -> QuoteT m a Source #

Monad m => Applicative ( QuoteT m) Source #
Instance details

Defined in PlutusCore.Quote

MonadIO m => MonadIO ( QuoteT m) Source #
Instance details

Defined in PlutusCore.Quote

Monad m => MonadQuote ( QuoteT m) Source #
Instance details

Defined in PlutusCore.Quote

MFunctor QuoteT Source #
Instance details

Defined in PlutusCore.Quote

Methods

hoist :: forall m n (b :: k). Monad m => ( forall a. m a -> n a) -> QuoteT m b -> QuoteT n b Source #

runQuoteT :: Monad m => QuoteT m a -> m a Source #

Run a quote from an empty identifier state. Note that the resulting term cannot necessarily be safely combined with other terms - that should happen inside QuoteT .

class Monad m => MonadQuote m Source #

A monad that allows lifting of quoted expressions.

Instances

Instances details
MonadQuote m => MonadQuote ( MaybeT m) Source #
Instance details

Defined in PlutusCore.Quote

MonadQuote m => MonadQuote ( PropertyT m) Source #
Instance details

Defined in PlutusCore.Quote

MonadQuote m => MonadQuote ( GenT m) Source #
Instance details

Defined in PlutusCore.Quote

Monad m => MonadQuote ( QuoteT m) Source #
Instance details

Defined in PlutusCore.Quote

MonadQuote m => MonadQuote ( ReaderT r m) Source #
Instance details

Defined in PlutusCore.Quote

MonadQuote m => MonadQuote ( StateT s m) Source #
Instance details

Defined in PlutusCore.Quote

MonadQuote m => MonadQuote ( ExceptT e m) Source #
Instance details

Defined in PlutusCore.Quote

MonadQuote m => MonadQuote ( RenameT ren m) Source #
Instance details

Defined in PlutusCore.Rename.Monad

( Stream s, MonadQuote m) => MonadQuote ( ParsecT e s m) Source #
Instance details

Defined in PlutusCore.Parser.ParserCommon

MonadQuote m => MonadQuote ( NormalizeTypeT m tyname uni ann) Source #
Instance details

Defined in PlutusCore.Normalize.Internal

Methods

liftQuote :: Quote a -> NormalizeTypeT m tyname uni ann a Source #

MonadQuote m => MonadQuote ( DefT key uni fun ann m) Source #
Instance details

Defined in PlutusIR.Compiler.Definitions

Methods

liftQuote :: Quote a -> DefT key uni fun ann m a Source #

Name generation

freshName :: MonadQuote m => Text -> m Name Source #

Get a fresh Name , given the annotation and the Text name.

freshTyName :: MonadQuote m => Text -> m TyName Source #

Get a fresh TyName , given the annotation and the Text name.

Evaluation

data EvaluationResult a Source #

The parameterized type of results various evaluation engines return. On the PLC side this becomes (via makeKnown ) either a call to Error or a value of the PLC counterpart of type a .

Instances

Instances details
Monad EvaluationResult Source #
Instance details

Defined in PlutusCore.Evaluation.Result

Functor EvaluationResult Source #
Instance details

Defined in PlutusCore.Evaluation.Result

MonadFail EvaluationResult Source #
Instance details

Defined in PlutusCore.Evaluation.Result

Applicative EvaluationResult Source #
Instance details

Defined in PlutusCore.Evaluation.Result

Foldable EvaluationResult Source #
Instance details

Defined in PlutusCore.Evaluation.Result

Traversable EvaluationResult Source #
Instance details

Defined in PlutusCore.Evaluation.Result

Alternative EvaluationResult Source #
Instance details

Defined in PlutusCore.Evaluation.Result

MonadError () EvaluationResult Source #
Instance details

Defined in PlutusCore.Evaluation.Result

( TypeError (' Text "\8216EvaluationResult\8217 cannot appear in the type of an argument") :: Constraint , uni ~ UniOf val) => ReadKnownIn uni val ( EvaluationResult a) Source #
Instance details

Defined in PlutusCore.Builtin.KnownType

MakeKnownIn uni val a => MakeKnownIn uni val ( EvaluationResult a) Source #
Instance details

Defined in PlutusCore.Builtin.KnownType

PrettyBy config a => PrettyBy config ( EvaluationResult a) Source #
Instance details

Defined in PlutusCore.Evaluation.Result

Eq a => Eq ( EvaluationResult a) Source #
Instance details

Defined in PlutusCore.Evaluation.Result

Show a => Show ( EvaluationResult a) Source #
Instance details

Defined in PlutusCore.Evaluation.Result

Generic ( EvaluationResult a) Source #
Instance details

Defined in PlutusCore.Evaluation.Result

NFData a => NFData ( EvaluationResult a) Source #
Instance details

Defined in PlutusCore.Evaluation.Result

PrettyClassic a => Pretty ( EvaluationResult a) Source #
Instance details

Defined in PlutusCore.Evaluation.Result

KnownTypeAst uni a => KnownTypeAst uni ( EvaluationResult a :: Type ) Source #
Instance details

Defined in PlutusCore.Builtin.KnownTypeAst

type Rep ( EvaluationResult a) Source #
Instance details

Defined in PlutusCore.Evaluation.Result

type Rep ( EvaluationResult a) = D1 (' MetaData "EvaluationResult" "PlutusCore.Evaluation.Result" "plutus-core-1.0.0.1-76bWF9ZEWyb4eDyjHx0kCS" ' False ) ( C1 (' MetaCons "EvaluationSuccess" ' PrefixI ' False ) ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 a)) :+: C1 (' MetaCons "EvaluationFailure" ' PrefixI ' False ) ( U1 :: Type -> Type ))
type ToHoles ( EvaluationResult a :: Type ) Source #
Instance details

Defined in PlutusCore.Builtin.KnownTypeAst

type ToBinds ( EvaluationResult a :: Type ) Source #
Instance details

Defined in PlutusCore.Builtin.KnownTypeAst

data UnliftingMode Source #

Determines how to unlift arguments. The difference is that with UnliftingImmediate unlifting is performed immediately after a builtin gets the argument and so can fail immediately too, while with deferred unlifting all arguments are unlifted upon full saturation, hence no failure can occur until that. The former makes it much harder to specify the behaviour of builtins and so UnliftingDeferred is the preferred mode.

Combining programs

applyProgram :: Monoid a => Program tyname name uni fun a -> Program tyname name uni fun a -> Program tyname name uni fun a Source #

Take one PLC program and apply it to another.

Benchmarking

termSize :: Term tyname name uni fun ann -> Size Source #

Count the number of AST nodes in a term.

typeSize :: Type tyname uni ann -> Size Source #

Count the number of AST nodes in a type.

kindSize :: Kind a -> Size Source #

Count the number of AST nodes in a kind.

>>> kindSize $ Type ()
Size {unSize = 1}
>>> kindSize $ KindArrow () (KindArrow () (Type ()) (Type ())) (Type ())
Size {unSize = 5}

programSize :: Program tyname name uni fun ann -> Size Source #

Count the number of AST nodes in a program.

serialisedSize :: Flat a => a -> Integer Source #

Compute the size of the serializabled form of a value.

Budgeting defaults

defaultBuiltinCostModel :: BuiltinCostModel Source #

The default cost model for built-in functions.

defaultCekMachineCosts :: CekMachineCosts Source #

Default costs for CEK machine instructions.

defaultCostModelParams :: Maybe CostModelParams Source #

The default cost model data. This is exposed to the ledger, so let's not confuse anybody by mentioning the CEK machine

CEK machine costs

cekMachineCostsPrefix :: Text Source #

The prefix of the field names in the CekMachineCosts type, used for extracting the CekMachineCosts component of the ledger's cost model parameters. See Note [Cost model parameters] in CostModelInterface.

data CekMachineCosts Source #

Costs for evaluating AST nodes. Times should be specified in picoseconds, memory sizes in bytes.

Constructors

CekMachineCosts

Fields

Instances

Instances details
Eq CekMachineCosts Source #
Instance details

Defined in UntypedPlutusCore.Evaluation.Machine.Cek.CekMachineCosts

Show CekMachineCosts Source #
Instance details

Defined in UntypedPlutusCore.Evaluation.Machine.Cek.CekMachineCosts

Generic CekMachineCosts Source #
Instance details

Defined in UntypedPlutusCore.Evaluation.Machine.Cek.CekMachineCosts

ToJSON CekMachineCosts Source #
Instance details

Defined in UntypedPlutusCore.Evaluation.Machine.Cek.CekMachineCosts

FromJSON CekMachineCosts Source #
Instance details

Defined in UntypedPlutusCore.Evaluation.Machine.Cek.CekMachineCosts

NFData CekMachineCosts Source #
Instance details

Defined in UntypedPlutusCore.Evaluation.Machine.Cek.CekMachineCosts

NoThunks CekMachineCosts Source #
Instance details

Defined in UntypedPlutusCore.Evaluation.Machine.Cek.CekMachineCosts

Lift CekMachineCosts Source #
Instance details

Defined in UntypedPlutusCore.Evaluation.Machine.Cek.CekMachineCosts

type Rep CekMachineCosts Source #
Instance details

Defined in UntypedPlutusCore.Evaluation.Machine.Cek.CekMachineCosts