Welcome to the new feature of the YF templating engine: easy extending with callbacks and support for compiled and non-compiled modes.
Best explanation can be done with examples:
tpl()->add_function_callback('my_new_tpl_func', function($m, $replace, $stpl_name) { return '__'.$m['args'].'__'; }); {my_new_tpl_func(testme)} #result: __testme__ tpl()->add_section_callback('my_new_tpl_section', function($m, $replace, $stpl_name) { return '__'.$m['args'].'__'.$m['body'].'__'; }); {my_new_tpl_section(k1=v1;k2=v2)} section_body {/my_new_tpl_section} #result: __k1=v1;k2=v2__section_body__
More working examples can be seen inside unit tests for this feature here:
https://github.com/yfix/yf/blob/master/.dev/tests/tpl/tpl_driver_yf_extend.Test.php
As usual with latest new features, it is fully covered with unit tests, ensuring it will continue to work correctly in future, after any possible code refactoring attempts or php version changes or in differetn supported environments.
P.S. I remind that minimal PHP version for YF 1.x series is PHP 5.3 (which means no support in core for PHP 5.2 and earlier versions, even for templating engine).
Currently all unit tests successfully passing on 2 CI servers (drone.io and travis-ci) with 5.3, 5.4, 5.5 PHP latest branch versions