diff options
Diffstat (limited to 'test.php')
-rw-r--r-- | test.php | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/test.php b/test.php new file mode 100644 index 0000000..c9a72ed --- /dev/null +++ b/test.php @@ -0,0 +1,18 @@ +<?php + +require("stupid_template_engine.php"); + +$file = file_get_contents("example/templates/src/master.html"); + +try { + $ast = \ste\Parser::parse($file, "master.html"); +} catch(\ste\ParseCompileError $e) { + $e->rewrite($file); + echo "Could not parse:\n"; + echo $e->getMessage(); + echo "\n"; + exit(1); +} + +echo "~~~~~~~~~~~\n"; +var_dump($ast);
\ No newline at end of file |