Bug 64649 - XSLT transformation - document('') doesn't return stylesheet
Summary: XSLT transformation - document('') doesn't return stylesheet
Status: NEW
Alias: None
Product: Taglibs
Classification: Unclassified
Component: XTags Taglib (show other bugs)
Version: nightly
Hardware: PC Linux
: P2 normal (vote)
Target Milestone: ---
Assignee: Tomcat Developers Mailing List
Depends on:
Reported: 2020-08-06 10:34 UTC by Stefan Pöschel
Modified: 2020-08-06 17:30 UTC (History)
0 users

Minimal test case JSP (845 bytes, application/xslt+xml)
2020-08-06 10:34 UTC, Stefan Pöschel

Note You need to log in before you can comment on or make changes to this bug.
Description Stefan Pöschel 2020-08-06 10:34:28 UTC
Created attachment 37384 [details]
Minimal test case JSP

According to § 12.1 of the W3C XSLT 1.0 spec, "document("") refers to the root node of the stylesheet".

However using JSP and the standard taglib, an empty sequence is returned in such case instead (please see attached a minimal example). I tested with v1.2.5 and also compiled the last SVN revision (as bug 60950 seems to be related to this issue).

When the affected XSLT is processed with a standalone version of Xalan (2.7.2), the document function works as expected though.