<?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>2709</bug_id>
          
          <creation_ts>2006-01-13 04:39:05 +0000</creation_ts>
          <short_desc>Wrong overflow for float sum in sumflt3args-6</short_desc>
          <delta_ts>2006-06-22 13:00:26 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>XML Query Test Suite</product>
          <component>XML Query Test Suite</component>
          <version>0.8.4</version>
          <rep_platform>PC</rep_platform>
          <op_sys>Linux</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="Jerome Simeon">simeon</reporter>
          <assigned_to name="Carmelo Montanez">carmelo</assigned_to>
          
          
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>7813</commentid>
    <comment_count>0</comment_count>
    <who name="Jerome Simeon">simeon</who>
    <bug_when>2006-01-13 04:39:06 +0000</bug_when>
    <thetext>sumflt3args-6

for the sum:
   fn:sum((xs:float(&quot;-3.4028235E38&quot;),
           xs:float(&quot;-3.4028235E38&quot;),
           xs:float(&quot;3.4028235E38&quot;)))

  Why wouldn&apos;t the result be -3.4028235E38? which is the sum
  of the three floats, and is within the range of floats.

  Note: that the F&amp;O document specifies the semantics through
  recursive function which will sum the last two floats first,
  but I am not sure whether we really impose this on implementations.

- Jerome</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>7878</commentid>
    <comment_count>1</comment_count>
    <who name="Andrew Eisenberg">andrew.eisenberg</who>
    <bug_when>2006-01-19 16:23:20 +0000</bug_when>
    <thetext>I believe that both -INF and -3.4028235E38 are supported by F&amp;O. The second
paragraph of 15.4.5 fn:sum contains the following:

&quot;The items in the resulting sequence may be reordered in an arbitrary order. The
resulting sequence is referred to below as the converted sequence.&quot;

The recursive function that you mention operates on the converted sequence.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>7881</commentid>
    <comment_count>2</comment_count>
    <who name="Jerome Simeon">simeon</who>
    <bug_when>2006-01-19 18:24:12 +0000</bug_when>
    <thetext>So I assume both results should be allowed by the test suite. Is that right?
- Jerome</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>7949</commentid>
    <comment_count>3</comment_count>
    <who name="Carmelo Montanez">carmelo</who>
    <bug_when>2006-01-23 16:35:36 +0000</bug_when>
    <thetext>Jerome:

You are correct.  Added extra expected results and submitted them.  Please
close the bug when able to verify.

Thanks,
Carmelo</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>8426</commentid>
    <comment_count>4</comment_count>
    <who name="Jerome Simeon">simeon</who>
    <bug_when>2006-02-23 18:41:21 +0000</bug_when>
    <thetext>This seems to be still wrong in 0.8.6. The catalog
indicates both -INF and an expected error FOAR0002,
but still not -3.4028235E38 as a possible result.

- Jerome</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>8675</commentid>
    <comment_count>5</comment_count>
    <who name="Carmelo Montanez">carmelo</who>
    <bug_when>2006-03-10 21:47:52 +0000</bug_when>
    <thetext>Jerome:

Sorry, I meant to add the extra file as well.  Generated another expected outcome to include -3.4028235E38.  Please close the bug if in agreement and when able to verify.

Thanks,
Carmelo     </thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>