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

PlutusIR.Generators.AST

Description

This module defines generators for PIR syntax trees for testing purposes. It should only contain those generators that can't be reused from PLC (PIR-exclusive constructs, Term, and Program)

Synopsis

Documentation

type AstGen = GenT (Reader [Name]) Source #

The monad that generators run in. The environment is a list of names to choose from for generation of variables and binders.

simpleRecursiveMonadGen m ⇒ [m a] → [m a] → m a Source #

runAstGenMonadGen m ⇒ AstGen a → m a Source #

genBuiltin ∷ (Bounded fun, Enum fun) ⇒ AstGen fun Source #

discardIfAnyConstantMonadGen m ⇒ (Some (ValueOf uni) → Bool) → m (Program tyname name uni fun ann) → m (Program tyname name uni fun ann) Source #