Split parseExp (for #3)

This commit is contained in:
bzick
2013-08-02 20:29:18 +04:00
parent f1d252a3cc
commit c27df81545
4 changed files with 168 additions and 118 deletions

View File

@ -32,6 +32,15 @@ class Compiler
*/
public static function tagInclude(Tokenizer $tokens, Template $tpl)
{
$name = false;
// if($tokens->is('[')) {
// $tokens->next();
// if(!$name && $tokens->is(T_CONSTANT_ENCAPSED_STRING)) {
// if($tpl->getStorage()->templateExists($_name = substr($tokens->getAndNext(), 1, -1))) {
// $name = $_name;
// }
// }
// }
$cname = $tpl->parsePlainArg($tokens, $name);
$p = $tpl->parseParams($tokens);
if ($p) { // if we have additionally variables