Support #4199

Stylesheet Export File incorrectly marking something as an EE feature

Added by Karl Franks 12 months ago. Updated 12 months ago.

Start date:
Due date:
% Done:


Legacy ID:
Applies to branch:
9.8, 9.9
Fix Committed on Branch:
Fixed in Maintenance Release:


Encountered seemingly a bug with the SEF feature where a predicate checking the value of an attribute is found in a sequence. When attempting to use the exported stylesheet with PE I'm getting an error "Cannot load expression with tag gcEE. The stylesheet uses Saxon-EE features".

I've cutdown the actual stylesheet I was attempting to export to just down to a template with the offending match predicate and verified that running the non-exported version with PE works just fine, but attempting to use the SEF version throws the same error.

I've tested various versions and the "gcEE" error seems to have been introduced in and is still present all the way up to

Attached is the stylesheet used to test this behaviour.

test-sef.xsl (569 Bytes) Karl Franks, 2019-04-17 13:32 test-sef.xsl


#1 Updated by Michael Kay 12 months ago

Did you specify a target edition when generating the SEF file? If you specify -target:PE on the command line then the optimizer should refrain from generating code that PE cannot execute. (However, the test cases for this area are probably not very comprehensive.)

#2 Updated by Karl Franks 12 months ago

Ahh ‍♂️, that'll be it.....I'll blame the fact someone else had started looking at SEF, and they didn't seem to be using the target option - and other stylesheets didn't seem to require it.

#3 Updated by Karl Franks 12 months ago

can confirm using that option it now seems to generate the correct SEF and works with PE just fine

also oh dear, just noticed my face palm emoji doesn't seem to have been handled by correctly and come out as a "♂️" instead....

#4 Updated by Michael Kay 12 months ago

  • Tracker changed from Bug to Support
  • Status changed from New to Closed

Please register to edit this issue

Also available in: Atom PDF