diff --git a/src/Picea/Extension.php b/src/Picea/Extension.php new file mode 100644 index 0000000..3ae9c3a --- /dev/null +++ b/src/Picea/Extension.php @@ -0,0 +1,33 @@ +register($context); + + $this->taxus = $taxus; + } + + public function register(Context $context) : void + { + $context->pushFunction("taxus", [ $this, 'taxus' ]); + } + + public function parse(/*\Picae\Compiler\Context*/ &$context, ?string $arguments, string $token) { + return ""; + } + + public function taxus(string $name, ...$arguments) : bool + { + return $this->taxus->granted($name, ...$arguments); + } + +}