Closed adonovan closed 1 month ago
Makes sense!
Are there any plans to move forward with this PR? In particular
we no longer treat the identifiers nil, true, false, iota, new, and make specially. All are legal identifiers, readily reused as field or method names without ambiguity, and the last three are not infrequently redefined as local variables.
would be nice to get in.
I have no plans to do anything with this PR. Feel free to take it over.
This PR changes short_var_declaration to accept only a list of identifiers on the left side. This prevents an (expression_list (identifier)) query from spuriously matching an identifier in a declaration.
Also:
I notice there is a tension here between what highlighting wants (mostly correct heuristics for things like new and iota) and what Stack Graphs wants (a minimal, regular, and semantically factored tree---since the program that converts TS trees to SG graphs can't express top-down recursive propagation of modal concepts like def vs. use).
Also, unrelated:
Checklist: