summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKevin Chabowski <kevin@kch42.de>2012-05-22 22:32:47 +0200
committerKevin Chabowski <kevin@kch42.de>2012-05-22 22:32:47 +0200
commitf1dfd489ae835d131da19319e640a2e5f3b9aa1c (patch)
treeba73f9bb0c7e8b7bab1247e2e275b2f62c1920bd
parent6240af533b446ed58f142e6c2131aac95d253e9e (diff)
downloadste-f1dfd489ae835d131da19319e640a2e5f3b9aa1c.tar.gz
ste-f1dfd489ae835d131da19319e640a2e5f3b9aa1c.tar.bz2
ste-f1dfd489ae835d131da19319e640a2e5f3b9aa1c.zip
Fixed broken infloop subcompiler.
-rw-r--r--stupid_template_engine.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/stupid_template_engine.php b/stupid_template_engine.php
index de6a89b..a8eba06 100644
--- a/stupid_template_engine.php
+++ b/stupid_template_engine.php
@@ -715,7 +715,7 @@ $ste_builtins = array(
},
"infloop" => function($ast)
{
- return "while(True)\n{\n" . loopbody(indent_code(_transcompile($ast->sub)) . "\n}") . "\n";
+ return "while(True)\n{\n" . indent_code(loopbody(indent_code(_transcompile($ast->sub)))) . "\n}\n";
},
"break" => function($ast)
{
@@ -1308,7 +1308,7 @@ class STECore
$content = precompile($content);
try
{
- $ast = parse($content, $tpl, 0);
+ $ast = parse($content, $tpl);
$transc = transcompile($ast);
}
catch(ParseCompileError $e)