Skip to content

hy-emit: add SPSC capability pipe prelude and emit lowering (#4464) - #4467

Open
SuperPiIot wants to merge 1 commit into
limitlessprojects:mainfrom
SuperPiIot:feat/emit-hy-pipe-capabilities-4464
Open

SuperPiIot wants to merge 1 commit into
limitlessprojects:mainfrom
SuperPiIot:feat/emit-hy-pipe-capabilities-4464

Conversation

@SuperPiIot

Copy link
Copy Markdown

Fixes #4464

Summary

  • Add PIPE_PRELUDE in hy-emit providing hy_send_cap[t any] (.send, .close), hy_recv_cap[t any] (.recv, .drain), and hy_pipe[t any](cap ...int) when pipe capabilities are used, while omitting "hy" from emitted Go imports.
  • Lower unshadowed hy.pipe[T](...) and hy.new_pipe[T](...) calls in expr.rs to hy_pipe[...](...), map hy.send_cap / hy.recv_cap Go type names and BindingKind::Chan provenance in lib.rs / stmt.rs (for for r in rx, select, closures, and typed var bindings).
  • Add integration tests in compiler/crates/hy-emit/tests/hy_pipe_capabilities_4464.rs (including go run -race) and ACCEPT corpus fixture tests/checker-corpus/hy-pipe-capabilities-accept.hy, updating corpus census surfaces (139 -> 140, ACCEPT 45 -> 46).

Verification

  • cargo test -p hy-emit --test hy_pipe_capabilities_4464: 4 passed, 0 failed (includes go run -race)
  • cargo test -p hy-diag -p hy-syntax -p hy-check -p hy-emit: 3217 passed, 0 failed
  • python3 tools/corpus_harness.py --bin target/debug/hyb: verdict agreement 140/140 (tripwire: not fired)
  • python3 tools/differential_loop.py --bin target/debug/hyb: accept-side (build+run) 48/48, reject-side (checker) 92/92 (FULL AGREEMENT)
  • hyb build --race tests/checker-corpus/hy-pipe-capabilities-accept.hy built and exited 0 (3 9)
  • python3 tools/check_corpus_census.py, check_guarantees.py, check_test_registration.py, check_conflict_markers.py, check_claims_links.py: OK

Settlement Coords

  • Network: Base Mainnet (Chain ID 8453)
  • Asset: USDC
  • Address: 0xf084cF0076F91AA48C2370F427C399dAA8C1f07F

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

1 participant