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 28856 - [FO31] serialize function error code
Summary: [FO31] serialize function error code
Status: CLOSED FIXED
Alias: None
Product: XPath / XQuery / XSLT
Classification: Unclassified
Component: Functions and Operators 3.1 (show other bugs)
Version: Candidate Recommendation
Hardware: PC Windows NT
: P2 normal
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-06-26 15:17 UTC by Debbie Lockett
Modified: 2016-12-16 19:55 UTC (History)
0 users

See Also:


Attachments

Description Debbie Lockett 2015-06-26 15:17:18 UTC
I think a new error code is needed for the case that the 2nd arg $params of fn:serialize() is supplied as a map, but the map contains parameter values which are not of the required type.

The error conditions section currently says:
'If any serialization error occurs, including the detection of an invalid value for a serialization parameter, this results in the fn:serialize call failing with a dynamic error.'
But I don't think this should cover the case above.
Comment 1 Michael Kay 2015-07-15 17:53:42 UTC
The decision just made on 28836 means that this should result in XPTY0004.
Comment 2 Michael Kay 2015-07-15 18:01:48 UTC
Note of further explanation: being of the wrong type here means, for example supplying a value for standalone that is not of type xs:boolean?. We're not validating against the schema definitions of the serialization parameters here. Specifying method="yaml" is not a type error in this sense, it is an invalid value for the parameter, and gives the SEPM error code for invalid serialization parameter values.
Comment 3 Michael Kay 2015-07-16 00:46:55 UTC
Applied the changes.