Repository navigation
fix(javascript): respect lexical shadowing of require - #509
Merged
morluto merged 1 commit intoOct 5, 2026
Merged
Conversation
Signed-off-by: RudyCelekli <[email protected]>
Owner
|
Thanks, @rudycelekli! The two-pass link plus shadowing check in both origin paths is a solid fix for hoisted/lexical |
darsrc
pushed a commit
to darsrc/rea
that referenced
this pull request
Oct 10, 2026
Signed-off-by: RudyCelekli <[email protected]>
This was referenced Oct 13, 2026
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.
Change
Collect module links after definitions, and honor lexical require shadowing during both origin-evaluation paths. Remove premature require directOrigins; retain static import origins and destructuring/alias/assignment evaluation. Controls cover function parameters, later hoisted declarations, later block const and imported loaders. Native inert-source analyzer; no JavaScript execution or provider claim.
Reproduction and verification
29 tests PASS; before4FAIL5PASS
npm run check:pr: passed (Test Files 352 passed (352); Tests 1803 passed | 2 skipped (1805)).npm run check:ci: passed.npm run verify:package: passed installed-tarball CLI/MCP verification, including optional-dependency degradation.npm pack --dry-run: passed.These tests exercise the production seams described above. No real Hopper, Ghidra, desktop browser or Linux sandbox end-to-end verification is claimed.
Prepared with AI assistance; the reproductions and verification commands above were executed locally.