def eq_add_cancel

bendtorch-core@0.1.0.0 · src/autograd/reduce_fiber_proof.bend:181

import bendtorch-core@0.1.0.0/src/autograd/reduce_fiber_proof.bend as ReduceFiberProof
import Base

181# a + x = a + y exactly when x = y.
182def eq_add_cancel(+a: Nat, +x: Nat, +y: Nat) -> {Nat.is_eq(Nat.add(a, x), Nat.add(a, y)) == Nat.is_eq(x, y) : Bool}:
183  match a:
184    case 0n:
185      {==}
186    case 1n+p:
187      eq_add_cancel(p, x, y)

Uses (4)

Used by (1)