Uploaded image for project: 'XalanJ2'
  1. XalanJ2
  2. XALANJ-2447

Effect of exclude-result-prefixes is cumulative across stylesheet modules with XSLTC

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.7.1
    • Component/s: None
    • Security Level: No security risk; visible to anyone (Ordinary problems in Xalan projects. Anybody can view the issue.)
    • Labels:
      None

      Description

      Section 7.1.1 of XSLT 1.0 states that "The designation of a namespace as an excluded namespace is effective within the subtree of the stylesheet rooted at the element bearing the exclude-result-prefixes or xsl:exclude-result-prefixes attribute; a subtree rooted at an xsl:stylesheet element does not include any stylesheets imported or included by children of that xsl:stylesheet element."

      However, XSLTC accumulates the declarations of exclude-result-prefixes in each included or imported stylesheet module into the set of excluded namespaces for the main stylesheet module.

      [1] http://www.w3.org/TR/xslt#literal-result-element

      1. j2447.actual.out
        0.2 kB
        Henry Zongaro
      2. j2447.expected.out
        0.3 kB
        Henry Zongaro
      3. j2447.patch.txt
        4 kB
        Henry Zongaro
      4. j2447.xsl
        0.6 kB
        Henry Zongaro
      5. j2447imp.xsl
        0.4 kB
        Henry Zongaro

        Activity

        Hide
        zongaro@ca.ibm.com Henry Zongaro added a comment -

        Attaching sample main stylesheet, imported stylesheet and expected output. Use any input to reproduce the problem.

        Show
        zongaro@ca.ibm.com Henry Zongaro added a comment - Attaching sample main stylesheet, imported stylesheet and expected output. Use any input to reproduce the problem.
        Hide
        zongaro@ca.ibm.com Henry Zongaro added a comment -

        Attaching current output with XSLTC.

        Show
        zongaro@ca.ibm.com Henry Zongaro added a comment - Attaching current output with XSLTC.
        Hide
        zongaro@ca.ibm.com Henry Zongaro added a comment -

        Corrected a typo in main stylesheet file.

        Show
        zongaro@ca.ibm.com Henry Zongaro added a comment - Corrected a typo in main stylesheet file.
        Hide
        zongaro@ca.ibm.com Henry Zongaro added a comment -

        Attaching a patch that resolves the problem

        Show
        zongaro@ca.ibm.com Henry Zongaro added a comment - Attaching a patch that resolves the problem
        Hide
        jycli@ca.ibm.com Christine Li added a comment -

        The patch has been reviewed and it looks good.

        Show
        jycli@ca.ibm.com Christine Li added a comment - The patch has been reviewed and it looks good.
        Hide
        zongaro@ca.ibm.com Henry Zongaro added a comment -

        Applied patch to source repository.

        Show
        zongaro@ca.ibm.com Henry Zongaro added a comment - Applied patch to source repository.
        Hide
        zongaro@ca.ibm.com Henry Zongaro added a comment -

        Updated fix version.

        Show
        zongaro@ca.ibm.com Henry Zongaro added a comment - Updated fix version.

          People

          • Assignee:
            zongaro@ca.ibm.com Henry Zongaro
            Reporter:
            zongaro@ca.ibm.com Henry Zongaro
            Reviewer:
            Christine Li
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development