Project

Profile

Help

Bug #3959

closed

Spurious warning: the attribute axis starting at a text node will never select anything

Added by Michael Kay almost 4 years ago. Updated almost 4 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
Diagnostics
Sprint/Milestone:
-
Start date:
2018-10-10
Due date:
% Done:

100%

Estimated time:
Legacy ID:
Applies to branch:
9.9
Fix Committed on Branch:
9.9
Fixed in Maintenance Release:
Platforms:

Description

This arises in the XSLT 3.0 test driver written in XSLT (runner/compare.xsl in the W3C test suite). The following two messages appear:

Warning at char 5 in xsl:copy-of/@select on line 156 column 50 of compare.xsl:
  SXWN9000: The attribute axis starting at a text node will never select anything
Warning at char 5 in xsl:copy-of/@select on line 161 column 50 of compare.xsl:
  SXWN9000: The attribute axis starting at a text node will never select anything

There are two problems:

(a) the messages appear repeatedly; warnings should only appear once.

(b) there's nothing wrong with the code in question. Line 156 is the xsl:copy-of instruction in

            <d:_1>
                <xsl:copy select="$a">
                    <xsl:copy-of select="$a/@*"/>
                </xsl:copy>
            </d:_1>

where $a has a declared type of node()?.

Please register to edit this issue

Also available in: Atom PDF