Skip to content

feat: parenthesized sub expressions with engine aware tokenization #879

Draft
jg-rp wants to merge 1 commit intoharttle:masterfrom
jg-rp:engine-aware-tokenizer-poc
Draft

feat: parenthesized sub expressions with engine aware tokenization #879
jg-rp wants to merge 1 commit intoharttle:masterfrom
jg-rp:engine-aware-tokenizer-poc

Conversation

@jg-rp
Copy link
Copy Markdown
Contributor

@jg-rp jg-rp commented Apr 14, 2026

This PR is an alternative implementation of parenthesized sub expressions, as described in #833 and #863.

In an attempt to throw "undefined filter" errors at parse-time rather than render-time, we've changed the Tokenizer constructor to require a Liquid argument, allowing us to look up filter implementations during tokenization.

A new PropToken type is defined for the benefit of PropertyAccessToken, and we've added Tokenizer.readProperty as an alternative to readValue() that explicitly excludes readGroupOrRange().

Please treat this PR as a proof of concept. It is far from ideal. I have copied some tests from #863 without forking and giving credit to @skynetigor.

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.

1 participant