getLine(); $ref = new LocalVariable(null, $lineno); $filter = $this->parser->getExpressionParser()->parseFilterExpressionRaw($ref); $this->parser->getStream()->expect(Token::BLOCK_END_TYPE); $body = $this->parser->subparse([$this, 'decideApplyEnd'], true); $this->parser->getStream()->expect(Token::BLOCK_END_TYPE); return new Nodes([ new SetNode(true, $ref, $body, $lineno), new PrintNode($filter, $lineno), ], $lineno); } public function decideApplyEnd(Token $token): bool { return $token->test('endapply'); } public function getTag(): string { return 'apply'; } }