AFTD Auto-Formalizing Theoretical Domains

PFunctor.FreeM

inductiveimported Lean

The free monad on a polynomial functor. This extends WType with an extra pure constructor.

Statement

set_option autoImplicit true in
set_option relaxedAutoImplicit true in
universe u v uA uB in
set_option genInjectivity false in
set_option genSizeOfSpec false in
inductive PFunctor.FreeM (P : PFunctor.{uA, uB}) : Type v → Type (max uA uB v)
  /-- A leaf node wrapping a pure value. -/
Defined in
CSLib, `PFunctor.FreeM`
Lean proof
By Quang Dao, from github.com/leanprover/cslib at 3951377e5a3f (Copyright (c) 2026 Quang Dao. All rights reserved, Apache-2.0). Compiled here against leanprover/lean4:v4.33.1, Mathlib v4.33.1; written for leanprover/lean4:v4.33.0.
Verified
08 Oct 2026
Axioms
none listed
Used by 46

Lean source view module on GitHub

set_option autoImplicit true in
set_option relaxedAutoImplicit true in
universe u v uA uB in
set_option genInjectivity false in
set_option genSizeOfSpec false in
/-- The free monad on a polynomial functor. This extends `WType` with an extra `pure` constructor. -/
inductive PFunctor.FreeM (P : PFunctor.{uA, uB}) : Type v → Type (max uA uB v)
  /-- A leaf node wrapping a pure value. -/ | protected pure {α} (a : α) : P.FreeM α
  /-- Invoke the operation `a : P.A` with continuation `cont : P.B a → P.FreeM α`. -/
  | liftBind {α} (a : P.A) (cont : P.B a → P.FreeM α) : P.FreeM α
deriving Inhabited
See it in the graphDiscuss this resultChallenge it