mirror of
https://github.com/twigphp/Twig.git
synced 2026-10-16 16:55:13 +00:00
Remove the new yield nodes
This commit is contained in:
@@ -28,9 +28,15 @@ class TextNode extends Node implements NodeOutputInterface
|
||||
|
||||
public function compile(Compiler $compiler): void
|
||||
{
|
||||
$compiler->addDebugInfo($this);
|
||||
|
||||
if ($compiler->getEnvironment()->useYield()) {
|
||||
$compiler->write('yield ');
|
||||
} else {
|
||||
$compiler->write('echo ');
|
||||
}
|
||||
|
||||
$compiler
|
||||
->addDebugInfo($this)
|
||||
->write('echo ')
|
||||
->string($this->getAttribute('data'))
|
||||
->raw(";\n")
|
||||
;
|
||||
|
||||
Reference in New Issue
Block a user