<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://www.w3.org/Bugs/Public/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4"
          urlbase="https://www.w3.org/Bugs/Public/"
          
          maintainer="sysbot+bugzilla@w3.org"
>

    <bug>
          <bug_id>14931</bug_id>
          
          <creation_ts>2011-11-25 09:51:06 +0000</creation_ts>
          <short_desc>[FO30] fn:format-number</short_desc>
          <delta_ts>2012-05-18 13:55:56 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>XPath / XQuery / XSLT</product>
          <component>Functions and Operators 3.0</component>
          <version>Member-only Editors Drafts</version>
          <rep_platform>PC</rep_platform>
          <op_sys>Windows NT</op_sys>
          <bug_status>CLOSED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Tim Mills">tim</reporter>
          <assigned_to name="Michael Kay">mike</assigned_to>
          <cc>jim.melton</cc>
          
          <qa_contact name="Mailing list for public feedback on specs from XSL and XML Query WGs">public-qt-comments</qa_contact>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>60477</commentid>
    <comment_count>0</comment_count>
    <who name="Tim Mills">tim</who>
    <bug_when>2011-11-25 09:51:06 +0000</bug_when>
    <thetext>fn:format-number has the following signature for its 3-argument variant.

fn:format-number($value 	 as numeric?,
                 $picture 	 as xs:string,
                 $decimal-format-name 	 as xs:string) as xs:string

Might I suggest changing it to:

fn:format-number($value 	 as numeric?,
                 $picture 	 as xs:string,
                 $decimal-format-name 	 as xs:string?) as xs:string

with behaviour such that if the $decimal-format-name is the empty sequence, the default decimal format is used.

Thus 

fn:format-number($value, $picutre) 

would be equivalent to 

fn:format-number($valud, $picture, ())</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>60585</commentid>
    <comment_count>1</comment_count>
    <who name="Michael Kay">mike</who>
    <bug_when>2011-11-28 23:37:04 +0000</bug_when>
    <thetext>I have no objection to this change. It&apos;s probably a good design principle that if there&apos;s a 3-argument form of a function and a 2-argument form, then there should always be a value for the 3rd argument that makes the call equivalent to the 2-argument form.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>60615</commentid>
    <comment_count>2</comment_count>
    <who name="Tim Mills">tim</who>
    <bug_when>2011-11-29 13:52:46 +0000</bug_when>
    <thetext>I think the two-argument format should also be marked context-dependent.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>62571</commentid>
    <comment_count>3</comment_count>
    <who name="Jim Melton">jim.melton</who>
    <bug_when>2012-01-11 19:47:47 +0000</bug_when>
    <thetext>In their Joint teleconference on 2011-12-06, the WGs decided to accept the proposal for the 3rd argument to fn:format-number to become xs:string?

I am not marking this bug RESOLVED pending the completion of the changes to F&amp;O 3.0.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>67796</commentid>
    <comment_count>4</comment_count>
    <who name="Michael Kay">mike</who>
    <bug_when>2012-05-16 21:51:29 +0000</bug_when>
    <thetext>The accepted changes have been applied to the spec baseline, so I am marking this resolved/fixed.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>67874</commentid>
    <comment_count>5</comment_count>
    <who name="Tim Mills">tim</who>
    <bug_when>2012-05-18 13:55:56 +0000</bug_when>
    <thetext>Thanks.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>