diff options
author | Kevin Chabowski <kevin@kch42.de> | 2013-10-25 21:44:02 +0200 |
---|---|---|
committer | Kevin Chabowski <kevin@kch42.de> | 2013-10-25 21:44:02 +0200 |
commit | dd03af69265ad686ae8daff6ecbd9df763e6d19f (patch) | |
tree | a86dae876afae2dcea9a3d70e3b513e305b38415 /docu/language_definition.html | |
parent | 91b965181f907b169aeeff63a6c15f9b8df9d9a9 (diff) | |
parent | eebf5cb885f266104333ac145355ef6e2599e5f6 (diff) | |
download | ste-dd03af69265ad686ae8daff6ecbd9df763e6d19f.tar.gz ste-dd03af69265ad686ae8daff6ecbd9df763e6d19f.tar.bz2 ste-dd03af69265ad686ae8daff6ecbd9df763e6d19f.zip |
Merge branch 'parser2'
STE gets a new, more robust parser. The previous parser was very fragile
and relied on some ugly regular expressions.
Other advantages of the new parser:
* No precompile phase to implement short tags (?{}, ~{}), that means
short tags can now be nested in any order.
* The parses now uses the mb_* functions, so it should handle non-ascii
text correctly.
There were also some improvements to the compiler:
* Various small bugfixes.
* The compiler accepts and compiles tag parameters that have tags in
them. The parser still doesn't accept this (and probably never will),
this is mainly used to allow arbitrary code inside of short cmp tags
(~{..}).
There are now (finally!) tests for the language to maintain a certain
quality and consistency (which STE lacked in the past, to be honest).
And finally the code was reformatted. Now 1TBS is used instead of
Allman.
Diffstat (limited to 'docu/language_definition.html')
-rw-r--r-- | docu/language_definition.html | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/docu/language_definition.html b/docu/language_definition.html index 77cb680..934042d 100644 --- a/docu/language_definition.html +++ b/docu/language_definition.html @@ -223,7 +223,6 @@ <p><code><ste:if>condition<ste:then>then</ste:then><ste:else>else</ste:else></ste:if></code></p> <p><code>?</code>, <code>{</code>, <code>|</code> and <code>}</code> can be <a href="#escaping">escaped</a></p> <p>In this variant, the else part <strong>is not optional</strong>!</p> - <p><strong>WARNING:</strong> short if-clauses can not be nested!</p> <h3 id="builtin_cmp">ste:cmp</h3> <p>With the ste:cmp tag you can compare two values.</p> @@ -285,9 +284,7 @@ <p><code>~{a|operator|b}</code></p> <p>This is equivalent to:</p> <p><code><ste:cmp text_a="a" op="operator" text_b="b" /></code></p> - <p><code>~</code>, <code>{</code>, <code>|</code> and <code>}</code> can be <a href="#escaping">escaped</a></p> - <p>Because this is implemented as a simple substitution, you can only use <a href="#basic_elems_text">Text</a> and <a href="#basic_elems_variable">Variables</a>. And <code>"</code> must be escaped.</p> - <p><strong>WARNING:</strong> short comparisons can not be nested! They can be inside <a href="#builtin_if_short">short if-clauses</a>, but not the other way around!</p> + <p><code>~</code>, <code>{</code>, <code>|</code> and <code>}</code> can be <a href="#escaping">escaped</a>.</p> <h3 id="builtin_not">ste:not</h3> <p>The ste:not Tag will logically invert its content. If it is an empty text (i.e. false), it will return a non-empty text (i.e. true) and vice versa.</p> |