def binary
import bendtorch-core@0.1.0.0/src/autograd/backward.bend as Backwardimport Base
305# Records `a op b`. An operand id the tape does not hold is refused with
306# UnknownNode, and the tape comes back unchanged.
307def binary(tape: Tape, kind: Binary, +a: Nat, +b: Nat) -> Tape & Result<&2, &2, Error, Nat>:
308 Tape{+entries} = tape
309 operands(entries, kind, a, b, value(Tape{entries}, a), value(Tape{entries}, b))