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 29312 - [XSLT30] First example in section does lack a format-number call
Summary: [XSLT30] First example in section does ...
Alias: None
Product: XPath / XQuery / XSLT
Classification: Unclassified
Component: XSLT 3.0 (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
Depends on:
Reported: 2015-11-29 11:05 UTC by Martin Honnen
Modified: 2016-10-06 18:42 UTC (History)
0 users

See Also:


Description Martin Honnen 2015-11-29 11:05:41 UTC
The first example in, according to the description, should produce the output

  <balance date="2008-09-01" value="12.00"/>
  <balance date="2008-09-01" value="20.00"/>
  <balance date="2008-09-02" value="18.00"/>
  <balance date="2008-09-02" value="23.00"/>

but as the code simply does

<balance date="{@date}" value="{$newBalance}"/>

the values are not properly formatted and lack the zeroes after the decimal point (e.g. value="12"), so the code needs to be fixed by using

<balance date="{@date}" value="{format-number($newBalance, '0.00')}"/>
Comment 1 Michael Kay 2015-12-10 15:26:10 UTC
Thanks, fixed. (No change log entry.)