phino-0.0.156: test-resources/evaluate-packs/spends-the-step-budget-on-a-branch-whose-phi-leads-back-to-it.yaml
# SPDX-FileCopyrightText: Copyright (c) 2025 Objectionary.com
# SPDX-License-Identifier: MIT
---
# yamllint disable rule:line-length
# The branch whose Ο fires the same fork again, with no '--acyclic' to cut it.
# The step of an 'unfold' line (#1885, #1921) fires the way an 'evaluate'
# line does, spending a step on every firing (#1882), so the step limit ends
# the run instead of letting the line fire the fork forever. This is the
# control the pack asking for the guard stands against.
symbolic: |
- Ξ»: L_fork
morph:
π1: $.a
π2: $.b
unfold:
π3: π1
join:
π4: [π3, π2]
π: π4
location: 'Q.y'
steps: 6
input: 'β¦ z β¦ β¦ Ο β¦ ΞΎ.f, f β¦ β¦ Ξ» β€ L_fork, a β¦ Ξ¦.z, b β¦ β¦ Ο β¦ β¦ Ξ» β€ π1 β§ β§ β§ β§, y β¦ β¦ a β¦ Ξ¦.z, b β¦ β¦ Ο β¦ β¦ Ξ» β€ π2 β§ β§, Ξ» β€ L_fork β§.Ο β§'
fails: 'reaching the limit of steps'
protocol: |
π(Ξ¦.y):
πΌ(L_fork):
π1Β·1 := β¦ Ο β¦ f, f β¦ β¦ Ξ» β€ L_fork, a β¦ Ξ¦.z, b β¦ π1:Ξ»:Ο β§ β§ # π(ΞΎ.a)
π2Β·1 := π2:Ξ»:Ο # π(ΞΎ.b)
π3Β·1 := β¦ Ξ» β€ L_fork, a β¦ Ξ¦.z, b β¦ π1:Ξ»:Ο β§ # π(π1.Ο)
πΌ(L_fork): # πΌ(π1)
π1Β·2 := β¦ Ο β¦ f, f β¦ β¦ Ξ» β€ L_fork, a β¦ Ξ¦.z, b β¦ π1:Ξ»:Ο β§ β§ # π(ΞΎ.a)
π2Β·2 := π1:Ξ»:Ο # π(ΞΎ.b)
π3Β·2 := β¦ Ξ» β€ L_fork, a β¦ Ξ¦.z, b β¦ π1:Ξ»:Ο β§ # π(π1.Ο)
πΌ(L_fork): # πΌ(π1)
π(Ξ¦.aπ΅6):
starved(6)