EmranMR / tree-sitter-blade

tree-sitter grammar for Laravel blade files
MIT License
186 stars 8 forks source link

BUG: Custom if_statement directives starting with letter "e" #8

Closed EmranMR closed 1 year ago

EmranMR commented 1 year ago

There is a bug with current "custom if-statment" grammar.js implementation whereby, the custom directive can not start with the letter "e". for example @exxx code @endxxx will not work. See the commit relating to #3

What happens when including "e"

The parser will be unable to pick up nesting correctly, using custom if_statements

The Reason behind the bug:

Simply because assertions such as lookahead and lookbehind are not supported in the RegEx when writing grammars in tree-sitter.

Fix:

This can possibly get fixed using external scanners, if someone proficient in C is happy to help. 🙃