Skip to content

Conversation

gamebox
Copy link
Collaborator

@gamebox gamebox commented Jun 29, 2025

This is A DRAFT. Feedback is welcome, but understand this will take a number of days to complete. I will post my work at the end of every day that I work on it. Hit me on Zulip if you want to talk about the approach in more detail.

Here is the high level plan:

  • Untyped parse nodes
  • Unified structure for all nodes that appear in two or more node types (Pattern, Expr, and TypeAnno)
  • Add parseUntypedNode function and related bits to parser
    • Only called in ambiguous parsing contexts like: Beginning of statement that does not state with keyword; Parsing top of block/record in expr parsing.
  • Untyped scratch
  • Functions to convert from untyped to typed nodes (hopefully just change tag)
  • After conversion, continue parsing where it would have been if we knew the type from the start.

Copy link

Thank you for your contribution! Sometimes PRs end up staying open for a long time without activity, which can make the list of open PRs get long and time-consuming to review. To keep things manageable for reviewers, this bot automatically closes PRs that haven’t had activity in 60 days. This PR hasn’t had activity in 30 days, so it will be automatically closed if there is no more activity in the next 30 days. Keep in mind that PRs marked Closed are not deleted, so no matter what, the PR will still be right here in the repo. You can always access it and reopen it anytime you like!

@gamebox
Copy link
Collaborator Author

gamebox commented Aug 7, 2025

Bump.

@gamebox
Copy link
Collaborator Author

gamebox commented Aug 7, 2025

This will probably needs to just be closed and carried on in a new PR since @lukewilliamboswell moves files around every month 😛

@gamebox gamebox closed this Aug 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant