code wiki / (root) / nx_step_parse.nx

nx_step_parse.nx

buildroot/runtime/nx_step_parse.nx

15035 B453 linesdepth 2pulls 2 transitivereach 21 importersview sourcekind librarytopic step
docsdependenciesstructsconstsfunctions

about

nx_step_parse.nx -- R1a STEP (ISO-10303-21) STRUCTURE parser LIB (no main; gated by nx_step_parse_gate). The explodeview-parity keystone: STEP is explodeview.com's ENTIRE input format and a named CAD gap since 07-01 (nx_step_import.nx never existed). SCOPE v0 = Part-21 lexing + entity table + the PRODUCT STRUCTURE spine: PRODUCT / PRODUCT_DEFINITION_FORMATION / PRODUCT_DEFINITION / NEXT_ASSEMBLY_USAGE_OCCURRENCE -> assembly tree + BOM. Geometry tessellation (analytic faces then NURBS) = R1b, its own rung. Lexer rules honored: quoted strings (double-quote-escape by doubling), /* */ comments, complex instances ( NAME(..)NAME(..) ), balanced-paren argument spans. The hash character (35) is matched NUMERICALLY -- never appears in an nx string literal (compiler gotcha). ctx st: *i64 slots: 0=buf 1=n 2=id[] 3=nameoff[] 4=namelen[] 5=argoff[] 6=arglen[] 7=count 8=cap. license_tier: ORIGINAL

dependencies 1 imports · 6 importers

nx_syscalls.nx nx_step_parse.nx nx_assemseq.nx nx_explode3d_gate.nx nx_explodelab_bomdims.nx nx_explodelab_treegen.nx nx_step_geom.nx nx_step_parse_gate.nx

imports: nx_syscalls.nx

imported by: nx_assemseq.nxnx_explode3d_gate.nxnx_explodelab_bomdims.nxnx_explodelab_treegen.nxnx_step_geom.nxnx_step_parse_gate.nx

structs

none

consts

none

functions

12func sp_puts(s: *u8) -> i64 { var n: i64 = 0; while s[n] != (0 as u8) { n = n + 1 } sys_write(1, s, n); return 0 }
13func sp_putn(v: i64) -> i64
27func sp_read_file(path: *u8, buf: *u8, cap: i64) -> i64
43func sp_init(st: *i64, buf: *u8, n: i64, aid: *i64, anm: *i64, anl: *i64, aao: *i64, aal: *i64) -> i64
called by 3: mainmainmain calls 1: sys_mmap
58func sp_skip_string(buf: *u8, n: i64, i: i64) -> i64
74func sp_skip_comment(buf: *u8, n: i64, i: i64) -> i64
called by 1: sp_scan
89func sp_isspace(c: i64) -> i64
97func sp_isnamec(c: i64) -> i64
called by 1: sp_statement
105func sp_args_span(buf: *u8, n: i64, v0: i64, out2: *i64) -> i64
called by 1: sp_statement calls 1: sp_skip_string
129func sp_statement(st: *i64, i: i64) -> i64
196func sp_scan(st: *i64) -> i64
211func sp_find(st: *i64, id: i64) -> i64
221func sp_name_is(st: *i64, idx: i64, s: *u8) -> i64
237func sp_name_prefix(st: *i64, idx: i64, s: *u8) -> i64
253func sp_name_out(st: *i64, idx: i64) -> i64
calls 1: sys_write
262func sp_first_ref(st: *i64, idx: i64) -> i64
called by 1: sp_pd_product calls 1: sp_skip_string
291func sp_arg_span(st: *i64, idx: i64, k: i64, out2: *i64) -> i64
330func sp_span_ref(buf: *u8, off: i64, len: i64) -> i64
called by 1: sp_nauo_collect calls 1: sp_isspace
354func sp_span_str_out(buf: *u8, off: i64, len: i64) -> i64
called by 1: spg_prod_out calls 2: sp_isspacesys_write
375func sp_prod_name_is(st: *i64, idx: i64, s: *u8) -> i64
405func sp_pd_product(st: *i64, pdid: i64) -> i64
426func sp_nauo_collect(st: *i64, pe: *i64, ce: *i64, cap: i64) -> i64