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
The way I've used it in the past is to avoid copying data when doing asynchronous writes. You could lock the buffer, get it's data pointer and pass it to libuv for example, since you know it will remain valid and stable. All one needs to do is to keep the Python object alive, which is simple to do by just bumping the refcount.
On to QuickJS :-) I found myself in the same situation. But now we have immutable aray buffers! I'd love to have a way to set / reset the flag from C, so I could keep the chunk I'm sending alive until libuv is done with it.
Say something like: JSArrayBuffer{Get,Set}Immutable(JSContext *ctx, JSObject obj, bool set).
Activity
Add JS_FreezeArrayBuffer
Add JS_FreezeArrayBuffer
Add JS_SetImmutableArrayBuffer (#1350)
Add JS_SetImmutableArrayBuffer (quickjs-ng#1350)
Add JS_SetImmutableArrayBuffer (quickjs-ng#1350)