phino-0.0.157: test-resources/evaluate-packs/joins-a-side-an-evaluate-line-fired-with-a-bool-it-left-as-it-is.yaml
# SPDX-FileCopyrightText: Copyright (c) 2025 Objectionary.com
# SPDX-License-Identifier: MIT
---
# yamllint disable rule:line-length
# The sides of a join may go through 'evaluate' lines (#1999). The left side
# morphs down to a call of 'L_eq' π left unfired, which could never join with
# a bool, so its 'evaluate' line fires it and binds the bool the entry
# answers. The right side is a bool already, a formation with no Ξ», so its
# 'evaluate' line leaves it as it is. The two bools differ in their symbols
# alone, and the join makes one term of them.
symbolic: |
- Ξ»: L_eq
π: Ξ¦.bool( Ο β¦ β¦ Ξ» β€ π β§ )
- Ξ»: L_fork
dataize:
πΏ1: $.c
morph:
π1: $.a
π2: $.b
evaluate:
π3: π1
π4: π2
join:
on: πΏ1
left: π3
right: π4
location: 'Q.y'
input: 'β¦ bool(Ο) β¦ β¦β§, y β¦ β¦ c β¦ β¦ Ξ» β€ π1 β§, a β¦ β¦ Ξ» β€ L_eq β§, b β¦ Ξ¦.bool( Ο β¦ β¦ Ξ» β€ π2 β§ ), Ξ» β€ L_fork β§.Ο β§'
result: 'π4:Ξ»'
protocol: |
π(Ξ¦.y):
πΌ(L_fork):
πΏ1Β·1 := π»(π1:Ξ») # π»(ΞΎ.c)
π1Β·1 := L_eq:Ξ» # π(ΞΎ.a)
π(Ξ¦.aπ΅2):
πΒ·1Β·1 := Ξ¦.bool( Ο β¦ π2:Ξ» )
π2Β·1 := πΒ·1Β·1 # π(ΞΎ.b)
πΌ(L_eq): # πΌ(π1)
πΒ·2Β·1 := Ξ¦.bool( Ο β¦ π3:Ξ» ) # π
π(πΒ·2Β·1):
πΒ·2Β·2 := Ξ¦.bool( Ο β¦ π3:Ξ» )
πΒ·2Β·3 := πΒ·2Β·2 # π(πΒ·2Β·1)
π3Β·1 := πΒ·2Β·3 # πΌ(π1)
π4Β·1 := π2Β·1 # πΌ(π2)
joined π4 := πΏ1Β·1 ? π3 : π2
πΒ·1Β·2 := π4:Ξ»:Ο # π3, π4