Project

Profile

Help

Bug #2582

closed

Internal error: expression element() has no retained static context

Added by Michael Kay over 8 years ago. Updated over 8 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
XSLT conformance
Sprint/Milestone:
-
Start date:
2016-01-12
Due date:
% Done:

100%

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

Description

Reported here:

https://saxonica.plan.io/boards/3/topics/6283

The failure occurs at compile time, but only under Saxon-HE (no failure under EE).

Actions #2

Updated by Michael Kay over 8 years ago

The submitter has simplified the test case to the following:

<xsl:stylesheet version="2.0" 
	xmlns:xsl="http://www.w3.org/1999/XSL/Transform">

	<xsl:template match="root/*[last()]"/> 
	
</xsl:stylesheet>

and this version also fails in Saxon-EE.

Aside: I thought there was supposed to be an optimization that replaced this by match="root/[not(following-sibling::)]".

Actions #3

Updated by Michael Kay over 8 years ago

Indeed, the failure occurs while Saxon is performing this very optimization.

Actions #4

Updated by Michael Kay over 8 years ago

  • Status changed from In Progress to Resolved
  • Fix Committed on Branch 9.7 added

I have applied a patch to the constructors for PatternWithPredicate and AncestorQualifiedPattern to make sure that parent pointers and static context pointers are correctly set during this optimization rewrite. This fixes the test case.

Actions #5

Updated by O'Neil Delpratt over 8 years ago

  • % Done changed from 0 to 100
  • Fixed in Maintenance Release 9.7.0.2 added

Bug fix applied in the Saxon 9.7.0.2 maintenance release

Actions #6

Updated by O'Neil Delpratt over 8 years ago

  • Status changed from Resolved to Closed

Please register to edit this issue

Also available in: Atom PDF