Project

Profile

Help

Bug #4328

closed

saxon:get-pseudo-attribute() returns empty string on no match

Added by Tony Graham over 4 years ago. Updated over 4 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
Saxon extensions
Sprint/Milestone:
-
Start date:
2019-10-01
Due date:
% Done:

0%

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

Description

saxon:get-pseudo-attribute() is documented [1] as returning an empty sequence on no match. It instead returns an empty string. This complicates checking for pseudo-attributes since it is not possible to distinguish an absent pseudo-attribute from one with a zero-length value.

The result of running the attached stylesheet:

$ java -jar c:/SaxonEE9-9-1-5J/saxon9ee.jar -it -xsl:get-pseudo-attribute.xsl
version: EE 9.9.1.5
pseudo: 'value' (true)
bogus: '' (true)

[1] http://www.saxonica.com/documentation/#!functions/saxon/get-pseudo-attribute


Files

get-pseudo-attribute.xsl (1.05 KB) get-pseudo-attribute.xsl Tony Graham, 2019-10-01 21:52

Please register to edit this issue

Also available in: Atom PDF