You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Implement the pinned private ArrayBuffer__fromSharedMemfd boundary as a directly testable ownership slice, separately from the opaque native JSC::ArrayBuffer handle API.
Acceptance
Match the pinned C ABI and selected Home/Bun JSType tags for ArrayBuffer and Uint8Array results.
Validate the file descriptor, total mapping size, and requested byte range without overflow or partial ownership.
Create a private read/write mapping of the complete declared region, expose the requested slice without copying, and never close or otherwise take ownership of the caller file descriptor.
Return an exact ordinary ArrayBuffer or Uint8Array; reject every other requested type and every invalid or unsupported mapping cleanly.
Unmap the complete original mapping exactly once on collection or context teardown, including construction-failure paths.
Prove slice identity and mutability, MAP_PRIVATE file isolation, non-zero offsets, invalid descriptors/ranges/types, GC, and teardown behavior with focused unit and compiled consumer tests.
Mark the export implemented in both pinned inventories, preserve zero unclassified entries, and update the README/private ABI evidence.
Non-goals
The opaque JSC__ArrayBuffer__ref, JSC__ArrayBuffer__deref, and JSC__ArrayBuffer__asBunArrayBuffer handle contract will be tracked as a separate child because it needs an explicit native handle producer and independent lifetime model.
Parent: #140
Tracked by: #134, #163, #164
Implement the pinned private
ArrayBuffer__fromSharedMemfdboundary as a directly testable ownership slice, separately from the opaque nativeJSC::ArrayBufferhandle API.Acceptance
JSTypetags forArrayBufferandUint8Arrayresults.ArrayBufferorUint8Array; reject every other requested type and every invalid or unsupported mapping cleanly.MAP_PRIVATEfile isolation, non-zero offsets, invalid descriptors/ranges/types, GC, and teardown behavior with focused unit and compiled consumer tests.Non-goals
The opaque
JSC__ArrayBuffer__ref,JSC__ArrayBuffer__deref, andJSC__ArrayBuffer__asBunArrayBufferhandle contract will be tracked as a separate child because it needs an explicit native handle producer and independent lifetime model.