mirror of
https://github.com/vercel-labs/scriptc.git
synced 2026-10-23 06:10:02 +08:00
- Add exact 64-bit and pointer ABIs, static node:ffi bindings, and Darwin framework linking. - Support native memory views and reusable callback pools with checked conversions and lifetime handling. - Preserve the JavaScript values, accessors, and module bindings used during renderer initialization.
10 lines
457 B
JavaScript
10 lines
457 B
JavaScript
const owners = new WeakMap();
|
|
const streams = new WeakSet();
|
|
for (const stream of [process.stdin, process.stdout, process.stderr]) {
|
|
console.log(owners.get(stream) === undefined, streams.has(stream));
|
|
owners.set(stream, stream.fd);
|
|
streams.add(stream);
|
|
}
|
|
console.log(owners.get(process.stdin), owners.get(process.stdout), owners.get(process.stderr));
|
|
console.log(streams.has(process.stdin), owners.delete(process.stdout), owners.has(process.stdout));
|