[go: up one dir, main page]

Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tidy up the grammar, Add support to db reference, and small fixes #5419

Merged
merged 3 commits into from
Sep 24, 2024

Conversation

OceanOak
Copy link
Collaborator
@OceanOak OceanOak commented Sep 23, 2024

No changelog

This PR:

  • Tidies up the tree-sitter Darklang grammar

  • Adds support for DB reference (e.g. Stdlib.DB.set Test { x = "test" } "key" TestDB)

  • Moves infix_operations from expressions to simple_expressions

  • Improves the handling of Record and List literals:
    Before: in a Record literal, variable names had to be wrapped in parentheses to avoid being parsed incorrectly (as an apply) . Example:

      Person
        { height = (height)
          name = (name) }
    

    Now: Parentheses are no longer necessary around variable names

      Person
        { height = height
          name = name}
    

    Tree-Sitter Grammar updates to make #5321

@OceanOak OceanOak marked this pull request as ready for review September 23, 2024 16:37
Copy link
Member
@StachuDotNet StachuDotNet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Really nice!

@StachuDotNet StachuDotNet merged commit 008af35 into darklang:main Sep 24, 2024
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants