X-Git-Url: http://www.aleph1.co.uk/gitweb/?p=yaffs-website;a=blobdiff_plain;f=vendor%2Fsymfony%2Fexpression-language%2FNode%2FFunctionNode.php;fp=vendor%2Fsymfony%2Fexpression-language%2FNode%2FFunctionNode.php;h=0000000000000000000000000000000000000000;hp=ab23acb94c738b346c9c0d29126032c82214f5cc;hb=9917807b03b64faf00f6a1f29dcb6eafc454efa5;hpb=aea91e65e895364e460983b890e295aa5d5540a5 diff --git a/vendor/symfony/expression-language/Node/FunctionNode.php b/vendor/symfony/expression-language/Node/FunctionNode.php deleted file mode 100644 index ab23acb94..000000000 --- a/vendor/symfony/expression-language/Node/FunctionNode.php +++ /dev/null @@ -1,52 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\ExpressionLanguage\Node; - -use Symfony\Component\ExpressionLanguage\Compiler; - -/** - * @author Fabien Potencier - * - * @internal - */ -class FunctionNode extends Node -{ - public function __construct($name, Node $arguments) - { - parent::__construct( - array('arguments' => $arguments), - array('name' => $name) - ); - } - - public function compile(Compiler $compiler) - { - $arguments = array(); - foreach ($this->nodes['arguments']->nodes as $node) { - $arguments[] = $compiler->subcompile($node); - } - - $function = $compiler->getFunction($this->attributes['name']); - - $compiler->raw(call_user_func_array($function['compiler'], $arguments)); - } - - public function evaluate($functions, $values) - { - $arguments = array($values); - foreach ($this->nodes['arguments']->nodes as $node) { - $arguments[] = $node->evaluate($functions, $values); - } - - return call_user_func_array($functions[$this->attributes['name']]['evaluator'], $arguments); - } -}