-
-
Notifications
You must be signed in to change notification settings - Fork 14.7k
De-Gc the AST #7929
Copy link
Copy link
Closed
Labels
C-cleanupCategory: PRs that clean code up or issues documenting cleanup.Category: PRs that clean code up or issues documenting cleanup.E-hardCall for participation: Hard difficulty. Experience needed to fix: A lot.Call for participation: Hard difficulty. Experience needed to fix: A lot.metabugIssues about issues themselves ("bugs about bugs")Issues about issues themselves ("bugs about bugs")
Metadata
Metadata
Assignees
Labels
C-cleanupCategory: PRs that clean code up or issues documenting cleanup.Category: PRs that clean code up or issues documenting cleanup.E-hardCall for participation: Hard difficulty. Experience needed to fix: A lot.Call for participation: Hard difficulty. Experience needed to fix: A lot.metabugIssues about issues themselves ("bugs about bugs")Issues about issues themselves ("bugs about bugs")
Type
Fields
Give feedbackNo fields configured for issues without a type.
It would be really nice to have an AST that was a tree with
~. This would have countless advantages, like the ast-fold could consume the AST and only allocate if it is actually creating a new node, and we'd generally not have the problems associated withGc(the GC might be able to land!).However, there are a few areas that are very tricky; mainly the AST map, which maps
node_idto actual AST nodes of various types, the only safe way to do this with an~tree is with&references... which freezes the AST for the remainder of the program, so no transformations like constant evaluation, and no consuming of the AST by trans.