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

PlutusIR.Test

Synopsis

Documentation

ppCatch ∷ (a → Doc ann) → ExceptT SomeException IO a → IO Text Source #

asIfThrownException e ⇒ Except e a → ExceptT SomeException IO a Source #

Adapt an computation that keeps its errors in an Except into one that looks as if it caught them in IO.

compileWithOpts ∷ (GEq uni, Typecheckable uni fun, Ord a, PrettyUni uni, Pretty fun, Pretty a, Default (BuiltinsInfo uni fun), Default (CostingPart uni fun), Default (RewriteRules uni fun)) ⇒ (CompilationCtx uni fun a → CompilationCtx uni fun a) → Program TyName Name uni fun a → Except (Error uni fun (Provenance a)) (Program TyName Name uni fun (Provenance a)) Source #

goldenPirPrettyPlc b ⇒ (a → b) → Parser a → StringTestNested Source #

goldenPirM ∷ ∀ a b. PrettyPlc b ⇒ (a → IO b) → Parser a → StringTestNested Source #

goldenPirUniquePretty b ⇒ (a → b) → Parser a → StringTestNested Source #

goldenPirMUnique ∷ ∀ a b. Pretty b ⇒ (a → IO b) → Parser a → StringTestNested Source #

goldenPirDoc ∷ (a → Doc ann) → Parser a → StringTestNested Source #

goldenPirDocM ∷ ∀ a ann. (a → IO (Doc ann)) → Parser a → StringTestNested Source #

initialSrcSpanFilePathSrcSpan Source #

A made-up SrcSpan for testing.

prettyPlcClassicSimplePrettyPlc a ⇒ a → Doc ann Source #

Pretty-print a PLC value without unique indices using the classic view.

Orphan instances

(GEq uni, Typecheckable uni fun, PrettyUni uni, Pretty fun, Pretty a, Typeable a, Ord a, Default (CostingPart uni fun), Default (BuiltinsInfo uni fun), Default (RewriteRules uni fun)) ⇒ ToTPlc (Program TyName Name uni fun a) uni fun Source # 
Instance details

Methods

toTPlcProgram TyName Name uni fun a → ExceptT SomeException IO (Program0 TyName Name uni fun ()) Source #

(GEq uni, Typecheckable uni fun, PrettyUni uni, Pretty fun, Hashable fun, Pretty a, Typeable a, Ord a, Default (CostingPart uni fun), Default (BuiltinsInfo uni fun), Default (RewriteRules uni fun)) ⇒ ToUPlc (Program TyName Name uni fun a) uni fun Source # 
Instance details

Methods

toUPlcProgram TyName Name uni fun a → ExceptT SomeException IO (Program0 Name uni fun ()) Source #