File: .lake/packages/lean4/src/lean/Lean/Compiler/LCNF/PullFunDecls.lean

full_name: Lean.Compiler.LCNF.PullFunDecls.ToPull
code: /--
Local function declaration and join point being pulled.
-/
structure ToPull where
  isFun : Bool
  decl  : FunDecl
  used  : FVarIdSet
  deriving Inhabited
goal: Type

full_name: Lean.Compiler.LCNF.PullFunDecls.ToPull.used
code: /--
Local function declaration and join point being pulled.
-/
structure ToPull where
  isFun : Bool
  decl  : FunDecl
  used  : FVarIdSet
  deriving Inhabited
goal: Lean.FVarIdSet

full_name: Lean.Compiler.LCNF.PullFunDecls.ToPull.isFun
code: /--
Local function declaration and join point being pulled.
-/
structure ToPull where
  isFun : Bool
  decl  : FunDecl
  used  : FVarIdSet
  deriving Inhabited
goal: Bool

full_name: Lean.Compiler.LCNF.PullFunDecls.instInhabitedToPull
code: /--
Local function declaration and join point being pulled.
-/
structure ToPull where
  isFun : Bool
  decl  : FunDecl
  used  : FVarIdSet
  deriving Inhabited
goal: Inhabited Lean.Compiler.LCNF.PullFunDecls.ToPull

full_name: Lean.Compiler.LCNF.PullFunDecls.ToPull.decl
code: /--
Local function declaration and join point being pulled.
-/
structure ToPull where
  isFun : Bool
  decl  : FunDecl
  used  : FVarIdSet
  deriving Inhabited
goal: Lean.Compiler.LCNF.FunDecl

full_name: Lean.Compiler.LCNF.PullFunDecls.PullM
code: /--
The `PullM` state contains the local function declarations and join points being pulled.
-/
abbrev PullM 
goal: Type

full_name: Lean.Compiler.LCNF.PullFunDecls.findFVarDirectDeps.go
code: /--
Extract from the state any local function declarations that depends on the given
free variable. The idea is that we have to stop pulling these declarations because they
depend on `fvarId`.
-/
def findFVarDirectDeps (fvarId : FVarId) : PullM (List ToPull) 
goal: Lean.CoreM (List Lean.Compiler.LCNF.PullFunDecls.ToPull × List Lean.Compiler.LCNF.PullFunDecls.ToPull)

full_name: Lean.Compiler.LCNF.PullFunDecls.findFVarDirectDeps
code: /--
Extract from the state any local function declarations that depends on the given
free variable. The idea is that we have to stop pulling these declarations because they
depend on `fvarId`.
-/
def findFVarDirectDeps (fvarId : FVarId) : PullM (List ToPull) 
goal: Lean.Compiler.LCNF.PullFunDecls.PullM (List Lean.Compiler.LCNF.PullFunDecls.ToPull)

full_name: Lean.Compiler.LCNF.PullFunDecls.findFVarDepsFixpoint
code: partial def findFVarDepsFixpoint (todo : List ToPull) (acc : Array ToPull := #[]) : PullM (Array ToPull) 
goal: Lean.Compiler.LCNF.PullFunDecls.PullM (Array Lean.Compiler.LCNF.PullFunDecls.ToPull)

full_name: Lean.Compiler.LCNF.PullFunDecls.findFVarDeps
code: partial def findFVarDeps (fvarId : FVarId) : PullM (Array ToPull) 
goal: Lean.Compiler.LCNF.PullFunDecls.PullM (Array Lean.Compiler.LCNF.PullFunDecls.ToPull)

full_name: Lean.Compiler.LCNF.PullFunDecls.findParamsDeps
code: /--
Similar to `findFVarDeps`. Extract from the state any local function declarations that depends on the given
parameters.
-/
def findParamsDeps (params : Array Param) : PullM (Array ToPull) 
goal: Lean.Compiler.LCNF.PullFunDecls.PullM (Array Lean.Compiler.LCNF.PullFunDecls.ToPull)

full_name: Lean.Compiler.LCNF.PullFunDecls.ToPull.attach
code: /--
Construct the code `fun p.decl k` or `jp p.decl k`.
-/
def ToPull.attach (p : ToPull) (k : Code) : Code 
goal: Lean.Compiler.LCNF.Code

full_name: Lean.Compiler.LCNF.PullFunDecls.attach.go
code: /--
Attach the given array of local function declarations and join points to `k`.
-/
partial def attach (ps : Array ToPull) (k : Code) : Code 
goal: StateM (Lean.Compiler.LCNF.Code × Array Bool) Unit

full_name: Lean.Compiler.LCNF.PullFunDecls.attach
code: /--
Attach the given array of local function declarations and join points to `k`.
-/
partial def attach (ps : Array ToPull) (k : Code) : Code 
goal: Lean.Compiler.LCNF.Code

full_name: Lean.Compiler.LCNF.PullFunDecls.attach.visit
code: /--
Attach the given array of local function declarations and join points to `k`.
-/
partial def attach (ps : Array ToPull) (k : Code) : Code 
goal: StateM (Lean.Compiler.LCNF.Code × Array Bool) Unit

full_name: Lean.Compiler.LCNF.PullFunDecls.attach.visited
code: /--
Attach the given array of local function declarations and join points to `k`.
-/
partial def attach (ps : Array ToPull) (k : Code) : Code 
goal: StateM (Lean.Compiler.LCNF.Code × Array Bool) Bool

full_name: Lean.Compiler.LCNF.PullFunDecls.attachFVarDeps
code: /--
Extract from the state any local function declarations that depends on the given
free variable, **and** attach to code `k`.
-/
partial def attachFVarDeps (fvarId : FVarId) (k : Code) : PullM Code 
goal: Lean.Compiler.LCNF.PullFunDecls.PullM Lean.Compiler.LCNF.Code

full_name: Lean.Compiler.LCNF.PullFunDecls.attachParamsDeps
code: /--
Similar to `attachFVarDeps`. Extract from the state any local function declarations that depends on the given
parameters, **and** attach to code `k`.
-/
def attachParamsDeps (params : Array Param) (k : Code) : PullM Code 
goal: Lean.Compiler.LCNF.PullFunDecls.PullM Lean.Compiler.LCNF.Code

full_name: Lean.Compiler.LCNF.PullFunDecls.attachJps
code: def attachJps (k : Code) : PullM Code 
goal: Lean.Compiler.LCNF.PullFunDecls.PullM Lean.Compiler.LCNF.Code

full_name: Lean.Compiler.LCNF.Decl.pullFunDecls
code: /--
Pull local function declarations and join points in the given declaration.
-/
def Decl.pullFunDecls (decl : Decl) : CompilerM Decl 
goal: Lean.Compiler.LCNF.CompilerM Lean.Compiler.LCNF.Decl

full_name: Lean.Compiler.LCNF.pullFunDecls
code: def pullFunDecls : Pass 
goal: Lean.Compiler.LCNF.Pass

full_name: Lean.Compiler.LCNF.initFn._@..lake.packages.lean4.src.lean.Lean.Compiler.LCNF.PullFunDecls._hyg.1765
code: builtin_initialize
  registerTraceClass `Compiler.pullFunDecls (inherited := true)
goal: IO Unit