protected function parseSnipCaller($buf) { $regex = '/ @(?P<snip_name>\\w+) # snip name ( @snipname ) /xA'; if ($buf->match($regex, $match)) { $snip_name = $match['snip_name']; $attributes = $this->parseSnipCallerAttributes($buf); $node = new SnipCaller($match['pos'][0], $snip_name, $this->env->currentMoreEnv, $attributes); $buf->skipWs(); if (null !== ($nested = $this->parseStatement($buf))) { $node->setContent($nested); } return $node; } }