Open
Description
Hi @fabpot
Twig-CS-Fixer use his own Lexer because
- he needs to keep space/tabs
- he uses more token types
The implementation worked fine so far, but just got recently broke by the 3.21 release since I inspired my getOperatorRegex
implementation by yours
Lines 547 to 551 in 3468920
I implemented a fix to follow your new implementation
Lines 528 to 530 in b54a265
(
, [
, =>
, ... for BC reason). But again getExpressionParsers
is internal.
Is there a way to write
$expressionParsers = ['='];
foreach ($this->env->getExpressionParsers() as $expressionParser) {
$expressionParsers = array_merge($expressionParsers, [$expressionParser->getName()], $expressionParser->getAliases());
}
without an internal method ? Would it be OK to make getExpressionParsers
part of the API ?
Thanks
Metadata
Metadata
Assignees
Labels
No labels