Allow jet script to not begin with jet tag. Treat as container.

This commit is contained in:
Brad Arant 2024-11-06 09:08:02 -08:00
parent b46694f71b
commit 489f1d6915
2 changed files with 4 additions and 1 deletions

View File

@ -95,7 +95,7 @@ namespace jet {
} }
} }
} else } else
throw coreutils::Exception("First character of (in) must be a <."); parseContainer(in);
} }
Tag::~Tag() { Tag::~Tag() {

View File

@ -1,7 +1,10 @@
#!../jet-2.0 #!../jet-2.0
This is a test
<set name="var1" value="abc" />
<jet cgi="true" name1="localname" filterblanklines="true" trimlines="true"> <jet cgi="true" name1="localname" filterblanklines="true" trimlines="true">
<for name="ix" start="1" end="20" step="1"> <for name="ix" start="1" end="20" step="1">
<set name="random" expr="random()" /> <set name="random" expr="random()" />
$[random] $[random]
</for> </for>
</jet> </jet>
$[var1]