Number.eg_neg: def of bend-collections-laws-math@1.0.0.0 Import: import bend-collections-laws-math@1.0.0.0/spec/math/number.bend as Number Lines 53-60 of bend-collections-laws-math@1.0.0.0/spec/math/number.bend: https://jend.leeeet.dev/read.txt?path=bend-collections-laws-math@1.0.0.0/spec/math/number.bend&start_line=53&end_line=60 import Base import bend-collections-laws-math@1.0.0.0/src/math/number.bend as NB def eg_neg(+a: Nat, +b: Nat, r: NB.EGcd) -> Nat: match r: case NB.EG{+g, +x, +y, neg}: match neg: case True{}: Nat.add(g, Nat.mul(a, x)) case False{}: Nat.add(g, Nat.mul(b, y)) Uses (5): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Bool https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat.add https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat.mul https://jend.leeeet.dev/definition.txt?path=bend-collections-laws-math@1.0.0.0/src/math/number.bend&name=EGcd