This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.

Bug 28526 - [XSLT30] (editorial) Unclear choice between XTSE0010 and XTSE0260
Summary: [XSLT30] (editorial) Unclear choice between XTSE0010 and XTSE0260
Status: CLOSED WORKSFORME
Alias: None
Product: XPath / XQuery / XSLT
Classification: Unclassified
Component: XSLT 3.0 (show other bugs)
Version: Last Call drafts
Hardware: PC Windows NT
: P2 trivial
Target Milestone: ---
Assignee: Michael Kay
QA Contact: Mailing list for public feedback on specs from XSL and XML Query WGs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-04-21 11:55 UTC by Abel Braaksma
Modified: 2015-10-29 09:50 UTC (History)
0 users

See Also:


Attachments

Description Abel Braaksma 2015-04-21 11:55:30 UTC
XTSE0260 should be raised if an xslt element is required to be empty, and XTSE0010 if any of its required attributes are wrong, or its content is incorrect.

In the case of:

<xsl:param name="x" required="yes">
    Fail with XTSE0260 | XTSE0010
</xsl:param>

the content MUST BE (is required to be) empty, so we use XTSE0260. But one could also argue that the content is incorrect to its semantics (Saxon raises XTSE0010, Exselt XTSE0260).

My guess would be: XTSE0260 is the correct error here.
Comment 1 Michael Kay 2015-04-21 13:16:23 UTC
I think with static errors it's often hard to be precise about error codes. For example if an attribute name is misspelt then you can either report that a required attribute is missing or that a disallowed attribute is present. Similarly here: you can argue that if required="yes" the content must be empty, or you can argue that if the content is non-empty, then you can't specify required="yes". I don't think we should spend time on this.
Comment 2 Abel Braaksma 2015-04-21 16:00:51 UTC
Yes, in retrospect I agree (my programmer and me came to the same conclusion in the end).

I'll close with WORKSFORME.