Update quickjs-ng to 2c620e4 and fix ArrayBuffer for new JS_NewArrayBuffer signature - #723
Open
richarddd wants to merge 10 commits into
Open
Update quickjs-ng to 2c620e4 and fix ArrayBuffer for new JS_NewArrayBuffer signature#723richarddd wants to merge 10 commits into
richarddd wants to merge 10 commits into
Conversation
Release 0.13.0
Release 0.12.2
richarddd
force-pushed
the
sync/quickjs-ng-bump
branch
3 times, most recently
from
August 9, 2026 04:18
21039a0 to
f0ffaf5
Compare
richarddd
force-pushed
the
sync/quickjs-ng-bump
branch
from
August 24, 2026 19:37
f0ffaf5 to
36033d3
Compare
Sytten
requested changes
Aug 28, 2026
…ArrayBufferDataFunc
richarddd
force-pushed
the
sync/quickjs-ng-bump
branch
from
August 29, 2026 07:04
f763aca to
810b2b6
Compare
psvensson
added a commit
to psvensson/lagrange-object-environment
that referenced
this pull request
Sep 2, 2026
The real lagrange-images portable-runtime.js closure (107 ES modules) SIGSEGV'd QuickJS-NG 0.15.1 at module LINK time (js_inner_module_linking NULL var_ref on cyclic re-export of an imported binding). Root-caused to a 3-module synthetic cycle with no Lagrange code; fixed upstream by quickjs-ng ef7a3a7 (first in 0.16.0). No released rquickjs carries a green engine, so pin rquickjs via [patch.crates-io] to PR DelSkayn/rquickjs#723 head rev 810b2b66 (bundles quickjs-ng 2c620e4). Exact rev, no floating branch, no vendoring; no lagrange-images semantic changes (fix owned at the engine boundary). The committed B0 probe goes RED -> GREEN: full_closure_links_and_exports_api proves the real closure now links, evaluates, exports the portable API (createPortableRuntime/createRuntimeCore/createPortableCodeExecutorRegistry) and preserves the crypto-provider contract, with zero Node resolution requests. All 26 js_env tests stay green (incl. both command-quiet liveness regressions). Falsified: reverting the pin restores the SIGSEGV. Crash guard retained (child exit-status based, with a --list rename guard). TextEncoder/TextDecoder are standard web-API host globals installed test-locally; 3zb-B decides the production surface. Deferred: s3b (unpin to a release), stx (CI images ref).
…backed buffers by reallocating through a mutable capacity cell.
… superseded stopgap where they conflicted.
Sytten
requested changes
Sep 7, 2026
| return core::ptr::null_mut(); | ||
| } | ||
| } else if new_len < capacity { | ||
| unsafe { vec.set_len(new_len) }; |
Collaborator
There was a problem hiding this comment.
Technically this is not safe because the current method allows:
#[derive(Copy, Clone)]
struct Point {
x: i32,
y: i32,
}
impl Drop on Point {
fn drop(&mut self) {
println!("Hello");
}
}
let vec = vec![Point { x:1, y:2 }];
ArrayBuffer::new(ctx, vec);If you use sel_len instead of truncate then the Drop is not called.
Collaborator
Author
There was a problem hiding this comment.
Fixed, switched to vec.truncate(new_len).
… drop glue always runs.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
quickjs-ng added a max_len param to JS_NewArrayBuffer and changed the free callback into a realloc callback, and moved ref_count out of the object body into the allocator header.
Updated both call sites and the callback signatures, regenerated bindings, and dropped the ref_count check in drop_context since that field is no longer readable.
Updated to quickjs-ng 0.16.2 (2c620e4), which includes several bug fixes on top of 0.16.0 with no further API changes.
Supersedes #722.