code wiki / _hdl_build / nx_pattern_emit3.nx

nx_pattern_emit3.nx

buildroot/runtime/_hdl_build/nx_pattern_emit3.nx

3701 B61 linesdepth 3pulls 3 transitivereach 6 importersview sourcekind librarytopic pattern
docsdependenciesstructsconstsfunctions

about

nx_pattern_emit3.nx -- PATTERN EMITTER: STATE_FLOW (shape 5 of 10 hands-off). The Builder authors a transitions-table state machine CORE from a small spec: <name>_step(state, ev) -> next state, or -1 (ILLEGAL -- the transition is refused, never silently coerced). This is the CMS draft->publish->rollback shape (also the print-job lifecycle and the login-session flow). The table is DATA (from,event,to triples), so the authored core is data-driven per global rule 11 -- no transition logic lives anywhere but the table. Test emission derives REAL KATs from the table itself: every legal row asserted, plus a mechanically-derived illegal pair (max-event+1) asserted refused. Extends nx_pattern_emit (CAPREG231) and nx_pattern_emit2 (CAPREG235). LAWS: struct-free, integer-only, no else-chains (flat ifs), no Claude core logic in the AUTHORED module. license_tier: ORIGINAL

dependencies 2 imports · 3 importers

nx_pattern_emit.nx nx_syscalls.nx nx_pattern_emit3.nx nx_cms_draft_team.nx nx_pattern_emit3_demo.nx nx_warden_build.nx

imports: nx_pattern_emit.nxnx_syscalls.nx

imported by: nx_cms_draft_team.nxnx_pattern_emit3_demo.nxnx_warden_build.nx

structs

none

consts

none

functions

15func pe3_emit_state_flow(fd: i64, name: *u8, t: *i64, nt: i64) -> i64
called by 1: pe3_author_state_flow calls 2: pe_wpe_wn
33func pe3_emit_state_flow_test(fd: i64, name: *u8, t: *i64, nt: i64) -> i64
55func pe3_author_state_flow(name: *u8, modpath: *u8, testpath: *u8, t: *i64, nt: i64) -> i64