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

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>16717</bug_id>
          
          <creation_ts>2008-01-03 00:45:56 -0800</creation_ts>
          <short_desc>parseFloat fails if string has trailing Euro symbol</short_desc>
          <delta_ts>2010-06-16 22:32:27 -0700</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>JavaScriptCore</component>
          <version>523.x (Safari 3)</version>
          <rep_platform>All</rep_platform>
          <op_sys>All</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>Major</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="rad2008">rad2008</reporter>
          <assigned_to name="Darin Adler">darin</assigned_to>
          <cc>ap</cc>
    
    <cc>darin</cc>
    
    <cc>hartman.wiki</cc>
    
    <cc>kangax</cc>
    
    <cc>mrowe</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>66108</commentid>
    <comment_count>0</comment_count>
    <who name="rad2008">rad2008</who>
    <bug_when>2008-01-03 00:45:56 -0800</bug_when>
    <thetext>Parsing a float with parseFloat() doesn&apos;t work with Euro symbol suffix.    

Sample script:
&lt;script&gt;
alert(parseFloat(&quot;1.0€&quot;));
&lt;/script&gt;

parseFloat returns NaN and NOT the expected value as float object;

This script works as expected:
&lt;script&gt;
alert(parseFloat(&quot;1.0$&quot;));
&lt;/script&gt;


My Test System:
Windows XP SP2
Safari 3.0.4 beta (523.15) with WebKit-r28899</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>66110</commentid>
    <comment_count>1</comment_count>
    <who name="Mark Rowe (bdash)">mrowe</who>
    <bug_when>2008-01-03 01:23:36 -0800</bug_when>
    <thetext>Confirmed on Mac OS X with both Safari 3.0.4 and TOT WebKit.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>66111</commentid>
    <comment_count>2</comment_count>
    <who name="Mark Rowe (bdash)">mrowe</who>
    <bug_when>2008-01-03 01:36:40 -0800</bug_when>
    <thetext>From ustring.cpp:

954	  // FIXME: If tolerateTrailingJunk is true, then we want to tolerate non-8-bit junk
955	  // after the number, so is8Bit is too strict a check.
956	  if (!is8Bit())
957	    return NaN;


</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>192569</commentid>
    <comment_count>3</comment_count>
    <who name="Derk-Jan Hartman">hartman.wiki</who>
    <bug_when>2010-02-22 12:50:58 -0800</bug_when>
    <thetext>This bug is a duplicate of Bug 31349</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>236612</commentid>
    <comment_count>4</comment_count>
    <who name="Derk-Jan Hartman">hartman.wiki</who>
    <bug_when>2010-06-10 17:59:17 -0700</bug_when>
    <thetext>This major data processing Javascript function is still broken....</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>236676</commentid>
    <comment_count>5</comment_count>
    <who name="Darin Adler">darin</who>
    <bug_when>2010-06-10 22:02:56 -0700</bug_when>
    <thetext>Well, if it’s major, then ... ;-)</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>236677</commentid>
    <comment_count>6</comment_count>
    <who name="Darin Adler">darin</who>
    <bug_when>2010-06-10 22:03:29 -0700</bug_when>
    <thetext>Well, to be serious, I was looking at this code recently and thinking I wanted to fix it, so I’ll grab this bug.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>239222</commentid>
    <comment_count>7</comment_count>
    <who name="Darin Adler">darin</who>
    <bug_when>2010-06-16 22:20:06 -0700</bug_when>
    <thetext>*** Bug 31349 has been marked as a duplicate of this bug. ***</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>239225</commentid>
    <comment_count>8</comment_count>
    <who name="Darin Adler">darin</who>
    <bug_when>2010-06-16 22:24:42 -0700</bug_when>
    <thetext>This was fixed in &lt;http://trac.webkit.org/changeset/56560&gt;.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>239227</commentid>
    <comment_count>9</comment_count>
    <who name="kangax">kangax</who>
    <bug_when>2010-06-16 22:32:27 -0700</bug_when>
    <thetext>However `Number(&apos;\u00A0&apos;)` still returns `NaN` (in today&apos;s nightly), so bug 31349 seems to be still in effect.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>