code wiki / _hdl_build / nx_connect_polls_lib.nx
nx_connect_polls_lib.nx
buildroot/runtime/_hdl_build/nx_connect_polls_lib.nx
about
nx_connect_polls_lib.nx -- the poll/ballot engine, extracted as a shared library so the verifying gate
(nx_connect_polls) and the LIVE app (nx_connect_serve /community) bind ONE implementation. The live tally
was previously a single stored choice with the counts recomputed inline -- structurally revote-replaces,
but a second expression of the rule rather than the verified engine.
THE LAW: one voter, one ballot. A revote REPLACES the voter's existing ballot in place, so a tally can
never inflate however many times someone votes. Counts are derived by scanning ballots, and the ballot
store holds the voter only so a re-vote can find it -- reported counts are aggregate, never per-person.
Symbols moved VERBATIM (no renames): renaming is what de-grounded compare rows on the earlier splits.
license_tier: ORIGINAL
dependencies 0 imports · 3 importers
imports: none
imported by: nx_connect_api_lib.nxnx_connect_polls.nxnx_connect_serve.nx
structs
| none |
consts
| 11 | const PL_MAXV: i64 = 64 |
functions
| 13 | func pl_vote(bv: *i64, bc: *i64, nb: *i64, meta: *i64, voter: i64, choice: i64) -> i64 |
| 30 | func pl_count(bc: *i64, nb: *i64, choice: i64) -> i64 |
| 37 | func pl_vote_append(bv: *i64, bc: *i64, nb: *i64, voter: i64, choice: i64) -> i64 called by 1: main |
| 44 | func pl_quiz_score(bv: *i64, bc: *i64, nb: *i64, meta: *i64, correct: i64, voter: i64) -> i64 called by 1: main |