Bug #4137
closedXsltTransformer.transform() starting at xsl:initial-template
100%
Description
It appears from https://stackoverflow.com/questions/54638824/setting-string-parameter-using-saxon-he-9-9-fails/54640211?noredirect=1#comment96179154_54640211 that in Saxon 9.8 it was possible (despite the absence of anything in the Javadoc saying so) to run a transformation starting at xsl:initial-template
by calling XsltTransformer.transform() with no previous call on setSource()
or setInitialTemplate()
; and that this no longer works in Saxon 9.9
Updated by Michael Kay almost 6 years ago
- Status changed from New to Resolved
- Applies to branch 9.9, trunk added
- Fix Committed on Branch 9.9, trunk added
I have reinstated the 9.8 behaviour and added Javadoc comments to make it official, and I have added a unit test.
Updated by Michael Kay over 5 years ago
The change was found to cause some existing unit tests to fail, particularly in the case where both a source and an initial template name were supplied. The logic is now:
- if an initial template name is supplied, use call-template() on that template name, whether or not setSource() was called;
- otherwise, if setSource() was called, do an apply-templates() on that source
- otherwise (no initial template name and no source), attempt call-template() on xsl:initial-template.
Updated by O'Neil Delpratt over 5 years ago
- Status changed from Resolved to Closed
- % Done changed from 0 to 100
- Fixed in Maintenance Release 9.9.1.2 added
Bug issue fixed in the Saxon 9.9.1.2 maintenance release.
Please register to edit this issue