Well I've looked more into Dreamweaver and found that it is very easy to add new tag types. I think I can come up with a compromise that will allow easy usage in Dreamweaver and allow my compiler to easily identify valid code.
It turns out that in Dreamweaver, if you want to include code escapes inside attributes, you really need to use what they call an empty tag. For example, jsp/asp tags: <% %>, there is no ending tag.
So at the moment, I'm considering the following examples as equivalent:
[if $x] [%if $x %]
[elseif {a==$b}] [%elseif {a==$b} %]
[else] [%else%]
[/if] [%/if%]
[set a b/] [%set a b /%]
[set a/] [%set a%] or [%= a /%] (ret value of a)
[foreach a $b] [%foreach a $b %]
[/foreach] [%/foreach%]
[resource text "header" ${title} /] ...
The templating language parser is helped by different ending tokens for tags like set and resource, thus the ending /] or /%] for those tags.