xsl:call-template not executed under Saxon-EE
The stylesheet appears to output a
<head> element under Saxon-HE (or Saxon-EE with no license), and the element is missing under Saxon-EE.
Reported by email to mike@.
#2 Updated by Michael Kay about 3 years ago
- Status changed from AwaitingInfo to In Progress
Weirdly, the user's hypothesis turns out to be correct: it fails when running with their particular license file, but not with other license files.
Looking more carefully, the license file has an unusual combination of options:
SAT=yes SAQ=yes SAV=no
The -explain output shows that the body of the
name="header" template is empty, accounting for the absence of any output when this template is called.
#3 Updated by Michael Kay about 3 years ago
It goes wrong at the point of bytecode generation.
As a consequence of SAT=yes, the option to generate bytecode is set on, but as a consequence of SAV=no, the method to generate bytecode returns null. As a consequence the body of the named template is null, and this results in a call on the template returning an empty sequence.
Two follow-up actions:
(a) issue the user a corrected license!
(b) put a check in the license-creation tool to prevent this happening again (it can happen when licenses are issued manually).
#4 Updated by Michael Kay about 3 years ago
- Fix Committed on Branch 9.8, 9.9 added
In case anything like this should happen again, and just for the sake of code robustness, I have changed Optimizer.makeByteCodeCandidate() to return the supplied expression unchanged (rather than null) in the case where no bytecode generation is performed. Patch applies to Optimizer.makeByteCodeCandidate() in 9.8 and 9.9.
Please register to edit this issue