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 16202 - [QT3TS] format-integer-061
Summary: [QT3TS] format-integer-061
Status: CLOSED FIXED
Alias: None
Product: XPath / XQuery / XSLT
Classification: Unclassified
Component: XQuery 3 & XPath 3 Test Suite (show other bugs)
Version: Member-only Editors Drafts
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: 2012-03-02 16:06 UTC by Tim Mills
Modified: 2012-05-18 15:28 UTC (History)
3 users (show)

See Also:


Attachments

Description Tim Mills 2012-03-02 16:06:29 UTC
The proposed change to format-integer in Bug 14858 gives no hint that the expected result for this test is correct.

I expected this test to mean that both primary format token and format modifier are the empty string, and thus the result would be equivalent to format-integer(1, '').

  <test-case name="format-integer-061">
        <description>format-integer - Error case with lone semicolon</description>
        <created by="Michael Kay, Saxonica" on="2012-02-28"/>
        <environment ref="empty"/>
        <test>format-integer(1, ';')</test>
        <result>
            <error code="XTDE0030"/>
        </result>    
    </test-case>
Comment 1 Michael Kay 2012-03-02 16:53:28 UTC
The general principle, which is retained under the new rules, is that a syntactically invalid picture is an error, whereas an unsupported-but-syntactically-legal picture leads to fallback behaviour. An empty picture string falls into the category of "syntactically invalid".
Comment 2 Michael Kay 2012-05-18 10:42:58 UTC
Looking at the spec again, I agree with Tim. The primary format token here is a zero-length string; the chances are that this is a format-token not recognized by the implementation, and the expected behaviour is therefore fallback to a format token of "1", giving the output "1".

Fixed accordingly.
Comment 3 Tim Mills 2012-05-18 15:28:46 UTC
Confirmed fixed.