Bug #5826
closed
In static expressions (e.g. use-when), XPath 4.0 functions are never available
Category:
Features new in 4.0
Applies to branch:
12, trunk
Fix Committed on Branch:
12, trunk
Fixed in Maintenance Release:
Description
In a use-when expression, or other static expression in an XSLT stylesheet, function-available('parse-html') always returns false even when 4.0 is enabled.
Fixed by making UseWhen30FunctionLibrary
have two instances, one for 31 and one for 40 (following the design of MapFunctionSet and ArrayFunctionSet); in UseWhenStaticContext
, use the 31 or 40 version depending on Feature.ALLOW_SYNTAX_EXTENSIONS.
Note, as well as the function library, this also makes XPath 40 syntax available in use-when expressions.
Needs further testing.
- Status changed from New to Resolved
Added XSLT40 test case use-when-4001.
After testing, changed the code so it depends on Compilation.getCompilerInfo().getXsltVersion()
, rather than depending directly on Feature.ALLOW_SYNTAX_EXTENSIONS
.
I needed to rework this fix because the original involved references from HE code into EE code.
Note, not planning to fix this for 11.x
- Status changed from Resolved to Closed
- % Done changed from 0 to 100
- Fixed in Maintenance Release 12.1 added
Bug fix applied in the Saxon 12.1 maintenance release.
Please register to edit this issue
Also available in: Atom
PDF