From 41605057a4ace86d6f96d2d7158bd614583fccee Mon Sep 17 00:00:00 2001 From: wait Date: Fri, 25 Sep 2020 12:35:57 +0300 Subject: [PATCH] Fix missing delimiter for preg_quote in lexer --- src/Lexer.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Lexer.php b/src/Lexer.php index 6fb8dd062..67d94ab92 100644 --- a/src/Lexer.php +++ b/src/Lexer.php @@ -117,7 +117,7 @@ class Lexer implements \Twig_LexerInterface // #} 'lex_comment' => '{ (?:'. - preg_quote($this->options['whitespace_trim']).preg_quote($this->options['tag_comment'][1], '#').'\s*\n?'. // -#}\s*\n? + preg_quote($this->options['whitespace_trim'].$this->options['tag_comment'][1], '#').'\s*\n?'. // -#}\s*\n? '|'. preg_quote($this->options['whitespace_line_trim'].$this->options['tag_comment'][1], '#').'['.$this->options['whitespace_line_chars'].']*'. // ~#}[ \t\0\x0B]* '|'.