code wiki / _hdl_build / nx_share_convergence_gate.nx

nx_share_convergence_gate.nx

buildroot/runtime/_hdl_build/nx_share_convergence_gate.nx

11364 B205 linesdepth 7pulls 10 transitivereach 0 importersview sourcekind gate/prooftopic share
docsdependenciesstructsconstsfunctions

about

nx_share_convergence_gate.nx -- THE DEDUP PROOF. I built nx_share_plane as a new who-may-see-what primitive and only afterwards found runtime/nx_rebac.nx, which calls itself "the ONE shared authorization plane for every Nishi surface" and exists precisely because the estate once had three incompatible authz philosophies. Mine would be a fourth. The irony is exact: nx_share_plane's whole justification was that shared gallery, shared contacts and gifts must not become three copies of one permission rule. The estate's law is to RETIRE a duplicate by PROVING CONVERGENCE, not by asserting redundancy. So this gate runs the SAME scenarios through both planes and compares verdicts, and it is deliberately built so that agreement is not the only outcome it can report: * an UNDECLARED divergence turns the gate RED -- two planes that disagree about who may see a photo is a privacy bug wearing a refactor's clothes; * a DECLARED divergence is printed with its reason and does NOT fail, because the point of the exercise is to find them. Two are declared below, and each one changes what "retire the duplicate" means. A gate that could only ever say "they agree" would prove nothing about a decision this consequential. license_tier: ORIGINAL expect_exit: 0

dependencies 2 imports · 0 importers

nx_rebac.nx nx_share_plane.nx nx_share_convergence_gate.nx

imports: nx_rebac.nxnx_share_plane.nx

imported by: nobody (leaf or entry point)

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

main c_w arena sp_slots_needed sp_init pfx rb_cat rb_catn sys_mmap sys_now_us sys_mmap ↻ sys_clock_gettime_mono cv c_w ↻ c_n sp_may sp_owner_of sp_at sp_live_cap sp_at ↻ rb_check sys_mmap ↻ rb_otype rb_seq rb_tuple_current sys_mmap ↻ ss_manifest_dyn ss_manifest_file_dyn sys_mmap ↻ ss_cat ss_readall sys_openat_rd sys_lseek sys_mmap ↻ sys_read sys_close sys_munmap rb_cat ↻ ss_readall ↻ ss_r32

structs

none

consts

19const CV_CAP: i64 = 64
20const CV_ALICE: i64 = 1001
21const CV_BOB: i64 = 1002
22const CV_CARA: i64 = 1003
23const CV_ALBUM: i64 = 7001

functions

25func c_w(s: *u8) -> i64 { var n: i64=0; while s[n]!=(0 as u8){n=n+1} sys_write(1,s,n); return 0 }
called by 2: cvmain
26func c_n(v: i64) -> i64
called by 2: cvmain
37func cv(label: *u8, mine: i64, theirs: i64, declared: i64, why: *u8, agree: *i64, div: *i64, fails: *i64) -> i64
called by 1: main calls 2: c_wc_n
55func arena() -> *i64
called by 1: main calls 2: sp_slots_neededsp_init
61func pfx(tag: i64) -> *u8
called by 1: main calls 3: rb_catrb_catnsys_now_us
69func main() -> i64