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

Implement a new parser #151

Merged
merged 2 commits into from
Jul 8, 2024
Merged

Implement a new parser #151

merged 2 commits into from
Jul 8, 2024

Conversation

williamthome
Copy link
Member

@williamthome williamthome commented Jul 6, 2024

Description

This PR implements a new parser called arizona_template_parser. It will replace arizona_tpl_parse.

I believe this PR's new module is enough for now. We "tokenize" the template using the arizona_template_scanner and organize it into "elements" using the arizona_template_parser. These elements are expected by the compiler to generate a "compiled" tree, i.e., the return of the arizona_live_view render callback is the return of the arizona_template_parser.

Closes #144.
Depends on #143. It has been merged.

@williamthome williamthome force-pushed the feat/template-parser branch 2 times, most recently from c2551ce to dbeb313 Compare July 8, 2024 17:05
@williamthome williamthome marked this pull request as ready for review July 8, 2024 17:13
Copy link
Member

@paulo-ferraz-oliveira paulo-ferraz-oliveira left a comment

Choose a reason for hiding this comment

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

Approved pending minor comments. Feel free to resolve to move forward:

  1. they're not super-relevant
  2. we already have a task to further look at the interface (Define which functions, types, ... are the interface #102)

😄

@paulo-ferraz-oliveira
Copy link
Member

Good stuff, @williamthome.

@williamthome
Copy link
Member Author

I'm putting this PR into draft. I'll change types to opaque and add support functions for them.

@williamthome
Copy link
Member Author

I'll keep types not opaque to keep going on.

@williamthome williamthome marked this pull request as ready for review July 8, 2024 20:28
@williamthome williamthome added this pull request to the merge queue Jul 8, 2024
Merged via the queue into main with commit a2b1e43 Jul 8, 2024
7 checks passed
@williamthome williamthome deleted the feat/template-parser branch July 8, 2024 20:38
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.

Implement a new parser
2 participants