nx_tptp_load_any.nx
buildroot/runtime/nx_tptp_load_any.nx
about
nx_tptp_load_any.nx -- TPTP loader handling both cnf(...) and fof(...).
The original nx_tptp_load_cnf_file only handles CNF statements --
adequate for hand-written test files but not for real CASC TPTP-Easy
problems which are typically in FOF format. This loader auto-detects
per statement and routes:
cnf(...) -> nx_tptp_parse_cnf_clause (existing path)
fof(...) -> nx_fof_parse + nx_fof_to_cnf, expand into CNF clauses
Role handling for FOF:
axiom / hypothesis / negated_conjecture / lemma / definition / plain
-> assert as-is (CNF-convert and append)
conjecture
-> NEGATE before CNF-converting (standard TPTP convention:
prove UNSAT of {axioms ∪ ¬conjecture})
All native NishiLang.
dependencies 16 imports · 1 importers
diagram shows first 10 each side; +6 more imports, +0 more importers in the complete lists below.
imports: nx_syscalls.nxnx_runtime.nxnx_tier.nxnx_str.nxnx_result.nxnx_file_result.nxnx_unify.nxnx_resolution.nxnx_tptp_symtab.nxnx_tptp_term.nxnx_tptp_formula.nxnx_tptp_load.nxnx_fof.nxnx_fof_parse.nxnx_fof_cnf.nxnx_fof_tseitin.nx
imported by: nx_casc_runner_test.nx
structs
| none |
consts
| 42 | const NX_LOAD_ANY_MAX_CLAUSES: nx_int = 256 |
| 43 | const NX_LOAD_ANY_FOF_CLAUSE_CAP: nx_int = 256 |
functions
| 52 | func nx_clause_dedup_lits(c: *Clause) -> *Clause |
| 75 | func nx_tptp_load_any_file(path: *u8, eq_sym: nx_int) -> *NxResult called by 1: run_problem calls 19: sys_mmapnx_read_file_resultnx_result_is_errnx_result_unwrapnx_tptp_symtab_newnx_tptp_load_skip+13 |