Skip to content

feat!: boundless interop#201

Merged
elringus merged 20 commits intomainfrom
feat/modules
May 7, 2026
Merged

feat!: boundless interop#201
elringus merged 20 commits intomainfrom
feat/modules

Conversation

@elringus
Copy link
Copy Markdown
Owner

@elringus elringus commented May 7, 2026

This resolves #153 by overhauling the way we handle values passed through the interop boundary:

  • Types with immutable semantics, such as structs, records and read-only collections are serialized and copied by value
  • Other non-primitive types (classes and interfaces) are considered mutable and passed by reference

Additionally, this PR:

  • Removes the limitation where "by-ref" types were only detected on the static interop boundary: now there is no limit on how deep such types can appear, as long as they are "user types" (BCL types are ignored to prevent leaking the whole .NET runtime into the generated interop layer)
  • Adds support for "by-ref" types inside serialized types; for example, a mutable class or interface can now appear inside a serialized struct, record or collection
  • Renames the concept of "static interfaces" to "modules" and removes the limitation where assembly-level [JSExport] attribute only accepted interfaces (it now works with non-static classes as well)

@elringus elringus added the enhancement New feature or enhancement label May 7, 2026
@codecov
Copy link
Copy Markdown

codecov Bot commented May 7, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 100.00%. Comparing base (f9e1dfd) to head (9c16cbb).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff            @@
##              main      #201   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           56        57    +1     
  Lines         2738      2778   +40     
  Branches       445       453    +8     
=========================================
+ Hits          2738      2778   +40     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@elringus elringus merged commit 2097afb into main May 7, 2026
8 checks passed
@elringus elringus deleted the feat/modules branch May 7, 2026 20:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or enhancement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Explore easing interop instance limitations

1 participant