Skip to content

fix(javascript): share dense inline array spread layout - #12564

Merged
morluto merged 7 commits into
audit/ambient-array-spread-originsfrom
audit/dense-inline-array-spreads
Nov 19, 2026
Merged

morluto merged 7 commits into
audit/ambient-array-spread-originsfrom
audit/dense-inline-array-spreads

Conversation

@morluto

@morluto morluto commented Nov 19, 2026 •

Copy link
Copy Markdown
Owner

Problem

Continues #7716, stacked on #12563. Array value evaluation, alias lookup, and destructuring each tracked array layout separately. A dense inline spread could lose a stable destination index or make a write appear to affect the wrong sibling.

Change

Use one bounded layout for evaluated values, property references, getter receivers, and read presence. Admit dense inline spreads when the native iterator is known at acquisition and the existing ambient effect log supports that proof. Retain uncertainty beyond opaque and sparse spreads. Report exhausted alias selection budgets through the existing recovery contract.

Validation

  • All 7,028 JavaScript source tests, the compiled CLI destructuring boundary, and check:fast passed on 4481c5e5ac.
  • The original review revision failed the added controls for opaque code, stale getter receivers, and missing budget diagnostics. The repaired head passes them and preserves controls for late effects, unrelated getter siblings, and unsupported layouts.
  • In paired CLI checks, the dense-spread dependency moved from candidate to resolved with stable IDs. These were static analyses of authored inputs.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 19, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-19T23:13:36.638290Z 4481c5e New commits
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@greptile-apps

greptile-apps Bot commented Nov 19, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerView in GreptileConfidence Score: 5/5

[Medium impact] The PR appears safe to merge based on the code review.

Summary

This PR gives array values, reference lookup, and destructuring one shared layout for dense inline spreads.

  • Dense inline spreads keep their destination slots aligned across JavaScript analysis.

All three previous findings are addressed. No new actionable issues were found. Runtime checks could not run because zod is not installed.

Reviews (2) · Last reviewed commit: "test(javascript): preserve getter fixtur..." · Reviewed by Greptile

@morluto
morluto merged commit 77b189a into audit/ambient-array-spread-origins Nov 19, 2026
1 check passed
@morluto
morluto deleted the audit/dense-inline-array-spreads branch November 19, 2026 23:14
morluto added a commit that referenced this pull request Nov 19, 2026
…ads (#12563)

* fix(javascript): retain ambient references through array spread

* fix(javascript): retain spread aliases to inherited iterator close hooks

* fix(javascript): share dense inline array spread layout (#12564)

* fix(javascript): share dense inline array spread layout

* fix(javascript): report exhausted dense spread layout allowance

* fix(javascript): preserve getter receivers through array spread

* fix(javascript): guard native array iteration from opaque global code

* test(javascript): group spread receiver controls

* test(javascript): preserve getter fixture tuple types

* fix(javascript): preserve spread slot projections for iterator receivers
@morluto morluto added bug Something isn't working area: native Native analysis and decompilation, including Ghidra, IDA, and Hopper analysis behavior labels Nov 22, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: native Native analysis and decompilation, including Ghidra, IDA, and Hopper analysis behavior bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant