toshok / toshok/echojs

ComputeFree needs to be a real NodeVisitor

Open
#2 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
431
Forks
20
PR merge metrics
No merged PRs in 30d

Description

right now the ComputeFree pass uses its own recursive tree walk code, where the return value of its visit (called "free") function is the free vars in that node's, instead of the node itself.

it needs to be rewritten to be a NodeVisitor like all the others. It should pass false to the NodeVisitor ctor so that a copy of the tree isn't made during traversal.r, but changing all the

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Locate the ComputeFree pass and the NodeVisitor implementation used by the other visitors. Compare its recursive tree walk and visit/free return behavior with those visitors, then trace how traversal is constructed. Done means ComputeFree is a NodeVisitor, passes false to its constructor, and preserves the intended free-variable results without copying the tree.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
compilers
Issue type
Refactor
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.