code wiki / (root) / nx_fin_dispute_gate.nx

nx_fin_dispute_gate.nx

buildroot/runtime/nx_fin_dispute_gate.nx

6370 B113 linesdepth 4pulls 5 transitivereach 0 importersview sourcekind gate/prooftopic fin
docsdependenciesstructsconstsfunctions

about

nx_fin_dispute_gate.nx -- R8 GATE: proves the audit findings (R5) flow into a correct, complete medical- bill DISPUTE LETTER (R8). Runs the real audit on the cancer-treatment bill, takes the three NON- OVERLAPPING structural findings (duplicate chemo $2,000 + unbundled blood draw $150 + over-units lab $500 = $2,650, each line disputed once so the total does not double-count), renders the letter, prints it, and asserts it cites the codes, dates, exact amounts, honest total, and the legal grounds. Fail-safe by construction: disp_build only writes to a buffer -- it cannot send anything. Exits 0 iff ALL pass. license_tier: ORIGINAL

dependencies 4 imports · 0 importers

nx_syscalls.nx nx_money.nx nx_fin_audit.nx nx_fin_dispute.nx nx_fin_dispute_gate.nx

imports: nx_syscalls.nxnx_money.nxnx_fin_audit.nxnx_fin_dispute.nx

imported by: nobody (leaf or entry point)

call flow from main pre-order; caps 40 nodes / depth 6 declared; ↻ = already shown

main sys_mmap seti aud_duplicates mny_add aud_unbundle mny_add ↻ aud_mue aud_lookup mny_div_round mny_div_floor mny_add ↻ chk g_puts sys_write g_putn sys_write ↻ sys_mmap ↻ disp_build d_cat d_n sys_mmap ↻ d_date d_n ↻ d_n2 d_money d_n ↻ d_n2 ↻ d_reason d_cat ↻ mny_add ↻ g_puts ↻ g_putn ↻ has gfind

structs

none

consts

none

functions

13func g_puts(s: *u8) -> i64 { var n: i64 = 0; while s[n] != (0 as u8) { n = n + 1 } sys_write(1, s, n); return 0 }
called by 2: chkmain calls 1: sys_write
14func g_putn(v: i64) -> i64
called by 2: chkmain calls 2: sys_writesys_mmap
23func chk(name: *u8, got: i64, want: i64, st: *i64) -> i64
called by 1: main calls 2: g_putsg_putn
28func gfind(hay: *u8, n: i64, needle: *u8) -> i64
called by 1: has
40func has(hay: *u8, n: i64, needle: *u8) -> i64 { if gfind(hay, n, needle) >= 0 { return 1 } return 0 }
called by 1: main calls 1: gfind
41func seti(a: *i64, i: i64, v: i64) -> i64 { a[i] = v; return 0 }
called by 1: main
43func main() -> i64