HTML Standard Tracker

Filter

File a bug

SVNBugCommentTime (UTC)
2433[Conformance Checkers] Ban year zero. (credit: hs)2008-11-25 09:52
@@ -2003,21 +2003,22 @@
   href="#refsGREGORIAN">[GREGORIAN]</a></p>
 
   <p>A string is a <dfn>valid month string</dfn> representing a year
   <var title="">year</var> and month <var title="">month</var> if it
   consists of the following components in the given order:</p>
 
   <ol>
 
    <li>Four or more <span
    title="concept-datetime-digit">digits</span>, representing <var
-   title="">year</var></li>
+   title="">year</var>, where <var
+   title="">year</var>&nbsp;&gt;&nbsp;0</li>
 
    <li>A U+002D HYPHEN-MINUS character (-)</li>
 
    <li>Two <span title="concept-datetime-digit">digits</span>,
    representing the month <var title="">month</var>, in the range
    0&nbsp;&le;&nbsp;<var
    title="">month</var>&nbsp;&le;&nbsp;12</li>
 
   </ol>
 
@@ -2054,20 +2055,23 @@
   means that it is aborted at that point and returns nothing.</p>
 
   <ol>
 
    <li><p><span>Collect a sequence of characters</span> in the range
    U+0030 DIGIT ZERO (0) to U+0039 DIGIT NINE (9). If the collected
    sequence is not at least four characters long, then
    fail. Otherwise, interpret the resulting sequence as a base-ten
    integer. Let that number be the <var title="">year</var>.</p></li>
 
+   <li><p>If <var title="">year</var> is not a number greater than
+   zero, then fail.</p></li>
+
    <li><p>If <var title="">position</var> is beyond the end of <var
    title="">input</var> or if the character at <var
    title="">position</var> is not a U+002D HYPHEN-MINUS character,
    then fail. Otherwise, move <var title="">position</var> forwards
    one character.</p></li>
 
    <li><p><span>Collect a sequence of characters</span> in the range
    U+0030 DIGIT ZERO (0) to U+0039 DIGIT NINE (9). If the collected
    sequence is not exactly two characters long, then fail. Otherwise,
    interpret the resulting sequence as a base-ten integer. Let that
@@ -2699,21 +2703,22 @@
   the Gregorian year <var title="">year</var>.</p>
 
   <p>A string is a <dfn>valid week string</dfn> representing a
   week-year <var title="">year</var> and week <var title="">week</var>
   if it consists of the following components in the given order:</p>
 
   <ol>
 
    <li>Four or more <span
    title="concept-datetime-digit">digits</span>, representing <var
-   title="">year</var></li>
+   title="">year</var>, where <var
+   title="">year</var>&nbsp;&gt;&nbsp;0</li>
 
    <li>A U+002D HYPHEN-MINUS character (-)</li>
 
    <li>A U+0057 LATIN CAPITAL LETTER W character</li>
 
    <li>Two <span title="concept-datetime-digit">digits</span>,
    representing the week <var title="">week</var>, in the range
    1&nbsp;&le;&nbsp;<var title="">week</var>&nbsp;&le;&nbsp;<var
    title="">maxweek</var>, where <var title="">maxweek</var> is the
    <span>week number of the last day</span> of week-year <var
@@ -2734,20 +2739,23 @@
    <li><p>Let <var title="">position</var> be a pointer into <var
    title="">input</var>, initially pointing at the start of the
    string.</p></li>
 
    <li><p><span>Collect a sequence of characters</span> in the range
    U+0030 DIGIT ZERO (0) to U+0039 DIGIT NINE (9). If the collected
    sequence is not at least four characters long, then
    fail. Otherwise, interpret the resulting sequence as a base-ten
    integer. Let that number be the <var title="">year</var>.</p></li>
 
+   <li><p>If <var title="">year</var> is not a number greater than
+   zero, then fail.</p></li>
+
    <li><p>If <var title="">position</var> is beyond the end of <var
    title="">input</var> or if the character at <var
    title="">position</var> is not a U+002D HYPHEN-MINUS character,
    then fail. Otherwise, move <var title="">position</var> forwards
    one character.</p></li>
 
    <li><p>If <var title="">position</var> is beyond the end of <var
    title="">input</var> or if the character at <var
    title="">position</var> is not a U+0057 LATIN CAPITAL LETTER W
    character, then fail. Otherwise, move <var title="">position</var>

|