code wiki / (root) / nx_macroprobe.nx

nx_macroprobe.nx

buildroot/runtime/nx_macroprobe.nx

1470 B30 linesdepth 4pulls 4 transitivereach 0 importersview sourcekind tool
docsdependenciesstructsconstsfunctions

about

nx_macroprobe.nx -- does @ifdef TARGET_X86_64 resolve CONSISTENTLY across imported files? nx_fcntl.nx compiled NX_SYS_FCNTL=25 (the @ifndef branch) while nx_syscalls.nx's numbers work. Both use the identical @ifdef TARGET_X86_64 / @ifndef pattern. If one file takes the x86 branch and another takes the riscv branch IN THE SAME BINARY, the macro is not applying uniformly. expect_exit: 0 license_tier: ORIGINAL

dependencies 2 imports · 0 importers

nx_syscalls.nx nx_fcntl.nx nx_macroprobe.nx

imports: nx_syscalls.nxnx_fcntl.nx

imported by: nobody (leaf or entry point)

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

main mp_puts sys_write mp_len mp_putn sys_write ↻ sys_mmap

structs

none

consts

none

functions

9func mp_len(s: *u8) -> i64 { var n: i64 = 0; while s[n] != (0 as u8) { n = n + 1 } return n }
called by 1: mp_puts
10func mp_puts(s: *u8) -> i64 { sys_write(1, s, mp_len(s)); return 0 }
called by 1: main calls 2: sys_writemp_len
11func mp_putn(v: i64) -> i64
called by 1: main calls 2: sys_writesys_mmap
22func main() -> i64
calls 2: mp_putsmp_putn