-
Notifications
You must be signed in to change notification settings - Fork 6
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
Parser Failing on Multi-Line Code #14
Comments
Fixed in v1.3.1. |
Hi @oscarotero! Would you mind taking a look at my code? I've been banging my head against the wall on this for quite some time, so your help would be much appreciated! |
I think the problem is in this line: https://gist.github.com/tvdijen/fc1016fbaa3aeac5a2bd50dad2e73114#file-compiledtwigtemplate-php-L69 The btw, there's a twig scanner (https://github.com/php-gettext/Twig-Scanner) but it's not stable enough so maybe it doesn't work either. |
Thanks @oscarotero ! I did find the twig-scanner, but the warning in the readme, and the lack of a stable release held me from trying it. I also understand from the open issues that it lacks support for Twig filters, and it lacks PHP 8 support. |
In the process of trying to upgrade from
php-gettext
version 4.x to 5.x in my code, and the following example code:Yields the error:
I believe this is because the parser isn't correctly handling the multiline string inside the function call.
The text was updated successfully, but these errors were encountered: