Skip to content

Commit

Permalink
[c] (0) Ban year zero. (credit: hs)
Browse files Browse the repository at this point in the history
git-svn-id: http://svn.whatwg.org/webapps@2433 340c8d12-0b0e-0410-8428-c7bf67bfef74
  • Loading branch information
Hixie committed Nov 25, 2008
1 parent 2913be0 commit ce040d0
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 4 deletions.
10 changes: 8 additions & 2 deletions index
Expand Up @@ -2741,7 +2741,7 @@
<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 <a href=#concept-datetime-digit title=concept-datetime-digit>digits</a>, representing <var title="">year</var></li>
<ol><li>Four or more <a href=#concept-datetime-digit title=concept-datetime-digit>digits</a>, representing <var title="">year</var>, where <var title="">year</var>&nbsp;&gt;&nbsp;0</li>

<li>A U+002D HYPHEN-MINUS character (-)</li>

Expand Down Expand Up @@ -2779,6 +2779,9 @@
fail. Otherwise, interpret the resulting sequence as a base-ten
integer. Let that number be the <var title="">year</var>.</li>

<li><p>If <var title="">year</var> is not a number greater than
zero, then fail.</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.</li>
Expand Down Expand Up @@ -3261,7 +3264,7 @@
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 <a href=#concept-datetime-digit title=concept-datetime-digit>digits</a>, representing <var title="">year</var></li>
<ol><li>Four or more <a href=#concept-datetime-digit title=concept-datetime-digit>digits</a>, representing <var title="">year</var>, where <var title="">year</var>&nbsp;&gt;&nbsp;0</li>

<li>A U+002D HYPHEN-MINUS character (-)</li>

Expand Down Expand Up @@ -3289,6 +3292,9 @@
fail. Otherwise, interpret the resulting sequence as a base-ten
integer. Let that number be the <var title="">year</var>.</li>

<li><p>If <var title="">year</var> is not a number greater than
zero, then fail.</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.</li>
Expand Down
12 changes: 10 additions & 2 deletions source
Expand Up @@ -2010,7 +2010,8 @@

<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>

Expand Down Expand Up @@ -2061,6 +2062,9 @@
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,
Expand Down Expand Up @@ -2706,7 +2710,8 @@

<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>

Expand Down Expand Up @@ -2741,6 +2746,9 @@
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,
Expand Down

0 comments on commit ce040d0

Please sign in to comment.