Borrowed Uint8Array.prototype.set.call hits a runtime fence in WASM binding code
Los mantenedores suelen responder en 1 día
@MathurAditya724 ya está trabajando en esto.
Desde el 20/10/2026.
- #1580 de @MathurAditya724 — abierto
Evaluación
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Aptitud para principiantes
- 15/100
- Tipo de issue
- Error
- Claridad
- Bien especificado
- Estado de actividad
- Estancado
- Stack tecnológico
- javascript, typescript, wasm
Línea de trabajo
Start with the linked pull request #1580, which proposes recognizing the borrowed typed-array call and routing it through a checked runtime helper. Review the two linked differential programs for typed and overlapping views and for checked-dynamic receivers and coercion order, then run the ordinary and sanitizer checks and the source-library feature matrix described in the issue. Done means the direct borrowed-call form matches Node's required semantics; the issue notes that broader CLI parity is outside scope.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
We are experimenting with compiling the complete Sentry CLI with scriptc, including its existing SQLite and debug-file processing dependencies, before benchmarking against the current Node SEA build. Generated WASM binding code uses a borrowed typed-array builtin to copy host bytes into linear memory; preserving that behavior is necessary to retain those dependencies.
Reproduction and expected behavior
Save as repro.mjs:
let cached = null;
function memory() {
if (cached === null) cached = new Uint8Array(4);
return cached;
}
function copy(target, source, offset) {
return Uint8Array.prototype.set.call(target, source, offset);
}
console.log(copy(memory(), new Uint8Array([3, 4]), 1));
console.log(String(memory()));
Node prints:
undefined
0,3,4,0
On unpatched main at 1ee5c84, the JavaScript-hosted compiler's analyze API reports no compile diagnostics or preflight failure for this example, but records one SC1090 runtime fence at the borrowed call:
Function.prototype.call on a function whose signature cannot cross the checked-value boundary (call 'Uint8Array.prototype.set(...)' directly) is not supported yet
This distinction matters: a build can succeed while execution is refused at the fence. Both statically known and checked-dynamic receivers need a supported path that produces the same result as Node. Replacing the borrowed builtin with target.set(...) is not equivalent when the receiver has its own set override.
Required semantics
Calling the builtin through .call must not look up a receiver's own set override. It must validate the receiver before offset coercion, preserve source access order, handle overlapping typed-array views and destination element conversion, enforce bounds, and return undefined. A DataView is invalid as the receiver; a plain DataView source has no length and copies zero elements. Primitive sources and offsets must retain their JavaScript behavior.
Proposed implementation and evidence
#1580 recognizes this exact builtin call and sends it to a checked runtime helper that reuses the existing typed-array copy/conversion implementation. The helper is a separate optional runtime unit, selected consistently for packaged and source-built executables and libraries under the existing dynamic-invocation feature.
The PR includes two self-contained Node/native differential programs: typed and overlapping views and checked-dynamic receivers and coercion order. Local ordinary and sanitizer runs pass, as does the four-way source-library feature matrix. A 33-workload comparison produces byte-identical IR, LLVM, and release executables without allow patterns.
This request is scoped to the direct borrowed-call form and the existing fixed-size view representation. The complete CLI still has other compatibility blockers; these checks do not establish full CLI parity or a runtime performance improvement.
- Lenguaje dominante
- TypeScript
- Estrellas
- 6.4k
- Forks
- 204
- Merge medio
- 7 h 44 min
- PR fusionados (30 d)
- 879
Preparar el entorno
- Sin Dockerfile ni archivo de Docker Compose
- Sin plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de vercel-labs/scriptc
-
Dificultad 4/5 3-5 días Aptitud para principiantes 22/100
vercel-labs/scriptc#2845 ·
Los mantenedores suelen responder en 1 día
-
Allow storing util.getCallSites without capturing a stackPosiblemente ocupada @jlucaso1 la tomó hoy. Abierto
Dificultad 4/5 3-5 días Aptitud para principiantes 35/100
vercel-labs/scriptc#2840 ·
Los mantenedores suelen responder en 1 día
-
Register shared JavaScript object globals with unmappable inferred fieldsPosiblemente ocupada @jlucaso1 la tomó hoy. Abierto
Dificultad 4/5 3-5 días Aptitud para principiantes 22/100
vercel-labs/scriptc#2837 ·
Los mantenedores suelen responder en 1 día
-
Hoisted TextEncoder feature probe returns false for encodeIntoPosiblemente ocupada @jlucaso1 la tomó hoy. Abierto
Dificultad 4/5 3-5 días Aptitud para principiantes 25/100
vercel-labs/scriptc#2836 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 5/5 Más de una semana Aptitud para principiantes 12/100
vercel-labs/scriptc#2810 ·
Los mantenedores suelen responder en 1 día
Todos los issues de vercel-labs/scriptc
Issues similares
-
[Bug]: Managed Tailscale Serve recovery misses "must be root" denial and skips sudo fallbackAbiertoclawsweeper:fix-shape-clear clawsweeper:queueable-fix clawsweeper:source-repro impact:other issue-rating: 🦞 diamond lobster maturity:stable no-stale P1
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
openclaw/openclaw#190772 · 1 comentario · 1 reacción ·
Los mantenedores suelen responder en 1 día
-
2026-11 good first issue gsoc-2027 project: virtual tests
Dificultad 2/5 Medio día Aptitud para principiantes 82/100
alphaonelabs/website#1150 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 70/100
flisk-sh/run-my-agents#61 ·
-
Dificultad 2/5 3-5 días Aptitud para principiantes 62/100
career-ops-hq/career-ops#6399 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
agents ai-agents area: cli claude-code difficulty: easy dx enhancement examples good first issue growth hacktoberfest help wanted island: Agent Isle island: Recipe Archipelago rank: 7 kyu tech: typescript
Dificultad 2/5 1-3 horas Aptitud para principiantes 62/100
tdk-landscape/tdk-cli-core#3126 ·