code wiki / (root) / nx_ontology_test.nx

nx_ontology_test.nx

buildroot/runtime/nx_ontology_test.nx

3211 B71 linesdepth 5pulls 6 transitivereach 0 importersview sourcekind gate/proof
docsdependenciesstructsconstsfunctions

about

nx_ontology_test.nx -- smoke for the substrate ontology primitive. Builds a synthetic ontology at /tmp/nx_ontology_t1.txt with known triples covering each predicate type, then verifies count + lookup + domain queries.

dependencies 4 imports · 0 importers

nx_syscalls.nx nx_tier.nx nx_str.nx nx_ontology.nx nx_ontology_test.nx

imports: nx_syscalls.nxnx_tier.nxnx_str.nxnx_ontology.nx

imported by: nobody (leaf or entry point)

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

main nx_ont_t_fixture sys_openat_wr nx_ont_t_write sys_write sys_close nx_ontology_load sys_mmap sys_read_file sys_openat_rd sys_lseek sys_mmap ↻ sys_read sys_close ↻ nx_ont_parse_line sys_mmap ↻ nx_str_cpy nx_ontology_n_triples nx_ontology_count_by_predi nx_str_eq nx_ontology_count_with_po nx_str_eq ↻ nx_ontology_has_triple nx_str_eq ↻ nx_ontology_in_domain nx_ontology_has_triple ↻

structs

none

consts

12const NX_ONT_T_MODE: i64 = 420 // 0o644

functions

14func nx_ont_t_write(fd: i64, s: *u8) -> nx_int
called by 1: nx_ont_t_fixture calls 1: sys_write
22func nx_ont_t_fixture(path: *u8) -> nx_int
40func main() -> nx_exit