MCPcopy
hub / github.com/di-sukharev/opencommit / isNonSharedArrayBuffer

Function isNonSharedArrayBuffer

out/cli.cjs:2579–2586  ·  view source on GitHub ↗
(value)

Source from the content-addressed store, hash-verified

2577 var abByteLengthGetter = Object.getOwnPropertyDescriptor(ArrayBuffer.prototype, "byteLength").get;
2578 var sabByteLengthGetter = typeof SharedArrayBuffer === "function" ? Object.getOwnPropertyDescriptor(SharedArrayBuffer.prototype, "byteLength").get : null;
2579 function isNonSharedArrayBuffer(value) {
2580 try {
2581 abByteLengthGetter.call(value);
2582 return true;
2583 } catch {
2584 return false;
2585 }
2586 }
2587 function isSharedArrayBuffer(value) {
2588 try {
2589 sabByteLengthGetter.call(value);

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…