Conditional matching
A failed match emits nothing. A successful match exposes match.* captures inside the xs:ifr body only; sibling blocks cannot observe them.
<xs:ifr get="arg.value" pattern="^(?<head>.)(?<tail>.*)$">
<xs:insert get="match.head"/>
</xs:ifr>Three read-only binding domains
file.*Information about the macro definition source.
arg.*Strings explicitly passed to this invocation.
match.*Named captures in the current ifr lexical block.
Output is always escaped
Use xs:insert to emit a scalar as escaped text. It never reparses <, >, or & as markup. Use xs:fill/xs:slot when structure must remain XML.