code wiki / _hdl_build / nx_web_harden_gate.nx
nx_web_harden_gate.nx
buildroot/runtime/_hdl_build/nx_web_harden_gate.nx
dependencies 3 imports · 0 importers
imports: nx_gate_base.nxnx_syscalls.nxnx_web_harden.nx
imported by: nobody (leaf or entry point)
call flow from main pre-order; caps 40 nodes / depth 6 declared; ↻ = already shown
structs
| none |
consts
| none |
functions
| 6 | func grow(name: *u8, ok: i64) -> i64 { if ok==1 { gw(" PASS " as *u8) } else { gw(" FAIL " as *u8) } gw(name); gw(" calls 1: gw |
| 8 | func pw(s: *u8) -> i64 { var n: i64=0; while s[n]!=(0 as u8){n=n+1} sys_write(1,s,n); return 0 } |
| 9 | func pn(v: i64) -> i64 { let b: *u8=sys_mmap(24); var m: i64=v; if m<0{pw("-" as *u8);m=0-m} let t: *u8=sys_mmap(24); var k: i64=0; if m==0{t[0]=48 as u8;k=1} while m>0{t[k]=(48+(m%10)) as u8;m=m/10;k=k+1} var i: i64=0; while i<k{b[i]=t[k-1-i];i=i+1} sys_write(1,b,k); return 0 } |
| 10 | func g_find(hay: *u8, hl: i64, needle: *u8, from: i64) -> i64 |
| 16 | func g_has(hay: *u8, hl: i64, needle: *u8) -> i64 { if g_find(hay,hl,needle,0)>=0 { return 1 } return 0 } called by 1: main |
| 17 | func g_count_byte(hay: *u8, hl: i64, b: i64) -> i64 { var c: i64=0; var i: i64=0; while i<hl { if (hay[i]&0xff)==b { c=c+1 } i=i+1 } return c } |
| 20 | func chk(label: *u8, ok: i64) -> i64 |
| 26 | func main(argc: i64, argv: *i64) -> i64 |