<?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>13689</bug_id>
          
          <creation_ts>2011-08-06 03:33:33 +0000</creation_ts>
          <short_desc>Floating point numbers beginning with a dot should be valid and parsed correctly</short_desc>
          <delta_ts>2011-10-05 18:08:42 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>HTML WG</product>
          <component>HTML5 spec</component>
          <version>unspecified</version>
          <rep_platform>Other</rep_platform>
          <op_sys>other</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc>http://www.whatwg.org/specs/web-apps/current-work/#floating-point-numbers</bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P3</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          <blocked>12220</blocked>
          <everconfirmed>1</everconfirmed>
          <reporter>contributor</reporter>
          <assigned_to name="Ian &apos;Hixie&apos; Hickson">ian</assigned_to>
          <cc>ayg</cc>
    
    <cc>ian</cc>
    
    <cc>jonas</cc>
    
    <cc>mike</cc>
    
    <cc>mounir</cc>
    
    <cc>Ms2ger</cc>
    
    <cc>public-html-admin</cc>
    
    <cc>public-html-wg-issue-tracking</cc>
          
          <qa_contact name="HTML WG Bugzilla archive list">public-html-bugzilla</qa_contact>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>54283</commentid>
    <comment_count>0</comment_count>
    <who name="">contributor</who>
    <bug_when>2011-08-06 03:33:33 +0000</bug_when>
    <thetext>Specification: http://www.whatwg.org/specs/web-apps/current-work/multipage/common-microsyntaxes.html#valid-floating-point-number
Multipage: http://www.whatwg.org/C#floating-point-numbers
Complete: http://www.whatwg.org/c#floating-point-numbers

Comment:
Is it intentional that floating point numbers beginning with a dot are not a
valid floating point numbers?  It took a fair amount of reading through the
spec to figure out why &lt;input type=&quot;number&quot; step=&quot;.5&quot;&gt; doesn&apos;t do what it
looks like it should do.  &lt;input type=&quot;number&quot; step=&quot;0.5&quot;&gt; of course works.

Posted from: 69.251.188.87
User agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_7) AppleWebKit/534.48.3 (KHTML, like Gecko) Version/5.1 Safari/534.48.3</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>54293</commentid>
    <comment_count>1</comment_count>
    <who name="Ian &apos;Hixie&apos; Hickson">ian</who>
    <bug_when>2011-08-06 03:55:27 +0000</bug_when>
    <thetext>Yes, it is intentional.

Maybe it should change?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>54370</commentid>
    <comment_count>2</comment_count>
    <who name="Ms2ger">Ms2ger</who>
    <bug_when>2011-08-07 20:54:54 +0000</bug_when>
    <thetext>Looks like Gecko already does this: &lt;http://software.hixie.ch/utilities/js/live-dom-viewer/?%3C!DOCTYPE%20html%3E%0A...%3Cprogress%20value%3D.7%3E&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>54381</commentid>
    <comment_count>3</comment_count>
    <who name="Aryeh Gregor">ayg</who>
    <bug_when>2011-08-08 14:40:01 +0000</bug_when>
    <thetext>Seems like something that should change -- there&apos;s no reason to make this invalid that I see.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>54412</commentid>
    <comment_count>4</comment_count>
    <who name="Ian &apos;Hixie&apos; Hickson">ian</who>
    <bug_when>2011-08-08 21:49:56 +0000</bug_when>
    <thetext>Opera also. Not WebKit.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>55608</commentid>
    <comment_count>5</comment_count>
    <who name="Jonas Sicking (Not reading bugmail)">jonas</who>
    <bug_when>2011-08-22 20:34:40 +0000</bug_when>
    <thetext>It&apos;s been brought up elsewhere that we should just use the same algorithm as ECMAScript uses to parse floats. This seems like a good idea to me and would fix this issue.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>55613</commentid>
    <comment_count>6</comment_count>
    <who name="Aryeh Gregor">ayg</who>
    <bug_when>2011-08-22 20:57:35 +0000</bug_when>
    <thetext>That&apos;s bug 12220 -- which is currently WONTFIX, so you should probably reopen it if you want it fixed.

I just looked again and discovered that this actually does affect implementer requirements, not just author requirements.  &quot;.5&quot; isn&apos;t just invalid, parsing it returns an error.  This seems very surprising.  From the summary, I thought it was just an authoring requirement.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>57855</commentid>
    <comment_count>7</comment_count>
    <who name="Ian &apos;Hixie&apos; Hickson">ian</who>
    <bug_when>2011-10-05 18:08:29 +0000</bug_when>
    <thetext>EDITOR&apos;S RESPONSE: This is an Editor&apos;s Response to your comment. If you are satisfied with this response, please change the state of this bug to CLOSED. If you have additional information and would like the editor to reconsider, please reopen this bug. If you would like to escalate the issue to the full HTML Working Group, please add the TrackerRequest keyword to this bug, and suggest title and text for the tracker issue; or you may create a tracker issue yourself, if you are able to do so. For more details, see this document:
   http://dev.w3.org/html5/decision-policy/decision-policy.html

Status: Accepted
Change Description: see diff given below
Rationale: Concurred with reporter&apos;s comments.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>57856</commentid>
    <comment_count>8</comment_count>
    <who name="">contributor</who>
    <bug_when>2011-10-05 18:08:42 +0000</bug_when>
    <thetext>Checked in as WHATWG revision r6635.
Check-in comment: Allow omission of the number before the period in a floating point number.
http://html5.org/tools/web-apps-tracker?from=6634&amp;to=6635</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>