New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

option binding problem with p:add-attribute #215

Closed
Conal-Tuohy opened this Issue Jul 25, 2015 · 0 comments

Comments

Projects
None yet
2 participants
@Conal-Tuohy
Contributor

Conal-Tuohy commented Jul 25, 2015

When attempting to add an attribute with a value taken from a variable, if the variable's name is $match, then the value of the p:add-attribute's match attribute is used, instead of the variable.

<p:declare-step version="1.0" name="test" xmlns:p="http://www.w3.org/ns/xproc">
    <p:output port="result"/>
    <p:variable name="match" select=" 'test' "/>
    <p:identity>
        <p:input port="source">
            <p:inline>
                <example/>
            </p:inline>
        </p:input>
    </p:identity>
    <p:add-attribute match="/*" attribute-name="example">
        <p:with-option name="attribute-value" select="$match"/>
    </p:add-attribute>
</p:declare-step>

Result:

<example example="/*"/>

Expected:

<example example="test"/>

(using xmlcalabash-1.1.4-95)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment