$node, 'arguments' => $arguments), array('name' => $name), $lineno); } public function compile(Twig_Compiler $compiler) { $name = $this->getAttribute('name'); $test = $compiler->getEnvironment()->getTest($name); $this->setAttribute('name', $name); $this->setAttribute('type', 'test'); $this->setAttribute('thing', $test); if ($test instanceof Twig_TestCallableInterface || $test instanceof Twig_SimpleTest) { $this->setAttribute('callable', $test->getCallable()); } $this->compileCallable($compiler); } }