MCPcopy Create free account
hub / github.com/BasisResearch/lean.py / apply

Method apply

lean_py/z3/tactic.py:124–134  ·  view source on GitHub ↗
(self, goal: Goal)

Source from the content-addressed store, hash-verified

122 self._tactics = tactics
123
124 def apply(self, goal: Goal) -> ApplyResult:
125 current = ApplyResult([goal])
126 for tac in self._tactics:
127 next_subgoals: list[Goal] = []
128 for sg in current._subgoals:
129 result = tac.apply(sg)
130 next_subgoals.extend(result._subgoals)
131 current = ApplyResult(next_subgoals)
132 if not current._subgoals:
133 break
134 return current
135
136
137class _OrElseTactic(Tactic):

Callers

nothing calls this directly

Calls 2

ApplyResultClass · 0.85
applyMethod · 0.45

Tested by

no test coverage detected