packages feed

phino-0.0.156: test-resources/evaluate-packs/remints-a-call-as-the-symbol-its-firing-answers.yaml

# SPDX-FileCopyrightText: Copyright (c) 2025 Objectionary.com
# SPDX-License-Identifier: MIT
---
# yamllint disable rule:line-length
# Morphing is lazy, so the tail of the pair below is still the call of 'L_inc'
# as the code spells it. A 'remint' step works such a term out the way an
# argument of a deferred copy is worked out since #1916: it morphs the term,
# fires what it comes to and writes every step, and the answer of 'L_inc' is
# a copy of 'Ξ¦.num' whose Ο† is the fresh symbol '𝜎2', so the tail is '𝜎2'
# (#1923).
symbolic: |
  - Ξ»: L_shrink
    morph:
      𝑛1: $.x
    rewrite:
      𝑛2:
        of: 𝑛1
        rules:
          - name: small-pair
            pattern: ⟦ !B1, head ↦ 𝑒1, tail ↦ 𝑒2, !B2 ⟧
            result: ⟦ !B1, head ↦ 𝑒3, tail ↦ 𝑒4, !B2 ⟧
            where:
              - meta: 𝑒3
                function: remint
                args: [𝑒1]
              - meta: 𝑒4
                function: remint
                args: [𝑒2]
    𝑛: 𝑛2
  - Ξ»: L_inc
    dataize:
      𝛿1: $.x
    𝑛: Ξ¦.num( Ο† ↦ ⟦ Ξ» ‍ 𝜎 ⟧ )
location: 'Q.y'
input: '⟦ num(Ο†) ↦ ⟦⟧, inc(x) ↦ ⟦ Ξ» ‍ L_inc ⟧, y ↦ ⟦ x ↦ ⟦ head ↦ ⟦ Ξ» ‍ 𝜎1 ⟧, tail ↦ Ξ¦.inc( ⟦ Ξ” ‍ 2A- ⟧ ) ⟧, Ξ» ‍ L_shrink ⟧.tail ⟧'
result: '𝜎2:λ'
protocol: |
  𝕄(Ξ¦.y):
    𝔼(L_shrink):
      𝑛1Β·1 := ⟦ head ↦ 𝜎1:Ξ», tail ↦ Ξ¦.inc( 2A-:Ξ” ) ⟧  # 𝕄(ΞΎ.x)
      𝕄(Ξ¦.inc( 2A-:Ξ” )):
        𝑛·1Β·1 := Ξ¦.inc( x ↦ 2A-:Ξ” )
      𝔼(L_inc):  # 𝔼(Ξ¦.inc( 2A-:Ξ” ))
        𝔻(Ξ¦.a🌡1):
          𝛿·2Β·1 := 2A-
        𝛿1Β·2 := 𝛿·2Β·1  # 𝔻(ΞΎ.x)
        𝑛·2Β·1 := Ξ¦.num( Ο† ↦ 𝜎2:Ξ» )  # 𝑛
        𝕄(𝑛·2Β·1):
          𝑛·2Β·2 := Ξ¦.num( Ο† ↦ 𝜎2:Ξ» )
        𝑛·2Β·3 := 𝑛·2Β·2  # 𝕄(𝑛·2Β·1)
      𝑛2Β·1 := ⟦ head ↦ 𝜎1:Ξ», tail ↦ 𝜎2:Ξ» ⟧  # 𝑛1
      𝑛·1Β·2 := ⟦ head ↦ 𝜎1:Ξ», tail ↦ 𝜎2:Ξ» ⟧  # 𝑛
      𝑛·1Β·3 := ⟦ head ↦ 𝜎1:Ξ», tail ↦ 𝜎2:Ξ» ⟧  # 𝕄(𝑛·1Β·2)