Skip to content

Commit

Permalink
Editorial: use "is 0" instead of "is zero" for consistency
Browse files Browse the repository at this point in the history
  • Loading branch information
ljharb committed Jan 29, 2018
1 parent bf8a9be commit c18b758
Showing 1 changed file with 11 additions and 11 deletions.
22 changes: 11 additions & 11 deletions spec.html
Original file line number Diff line number Diff line change
Expand Up @@ -3446,7 +3446,7 @@ <h1>ToBoolean ( _argument_ )</h1>
String
</td>
<td>
If _argument_ is the empty String (its length is zero), return *false*; otherwise return *true*.
If _argument_ is the empty String (its length is 0), return *false*; otherwise return *true*.
</td>
</tr>
<tr>
Expand Down Expand Up @@ -26711,7 +26711,7 @@ <h1>Year Number</h1>
<emu-eqn id="eqn-TimeFromYear" aoid="TimeFromYear">TimeFromYear(_y_) = msPerDay &times; DayFromYear(_y_)</emu-eqn>
<p>A time value determines a year by:</p>
<emu-eqn id="eqn-YearFromTime" aoid="YearFromTime">YearFromTime(_t_) = the largest integer _y_ (closest to positive infinity) such that TimeFromYear(_y_) &le; _t_</emu-eqn>
<p>The leap-year function is 1 for a time within a leap year and otherwise is zero:</p>
<p>The leap-year function is 1 for a time within a leap year and otherwise is 0:</p>
<emu-eqn id="eqn-InLeapYear" aoid="InLeapYear">InLeapYear(_t_)
= 0 if DaysInYear(YearFromTime(_t_)) = 365
= 1 if DaysInYear(YearFromTime(_t_)) = 366
Expand Down Expand Up @@ -27152,7 +27152,7 @@ <h1>Date.now ( )</h1>
<emu-clause id="sec-date.parse">
<h1>Date.parse ( _string_ )</h1>
<p>The `parse` function applies the ToString operator to its argument. If ToString results in an abrupt completion the Completion Record is immediately returned. Otherwise, `parse` interprets the resulting String as a date and time; it returns a Number, the UTC time value corresponding to the date and time. The String may be interpreted as a local time, a UTC time, or a time in some other time zone, depending on the contents of the String. The function first attempts to parse the format of the String according to the rules (including extended years) called out in Date Time String Format (<emu-xref href="#sec-date-time-string-format"></emu-xref>). If the String does not conform to that format the function may fall back to any implementation-specific heuristics or implementation-specific date formats. Unrecognizable Strings or dates containing illegal element values in the format String shall cause `Date.parse` to return *NaN*.</p>
<p>If `x` is any Date object whose milliseconds amount is zero within a particular implementation of ECMAScript, then all of the following expressions should produce the same numeric value in that implementation, if all the properties referenced have their initial values:</p>
<p>If `x` is any Date object whose milliseconds amount is 0 within a particular implementation of ECMAScript, then all of the following expressions should produce the same numeric value in that implementation, if all the properties referenced have their initial values:</p>
<pre><code class="javascript">
x.valueOf()
Date.parse(x.toString())
Expand Down Expand Up @@ -27759,7 +27759,7 @@ <h1>Date.prototype.toString ( )</h1>
1. Return ToDateString(_tv_).
</emu-alg>
<emu-note>
<p>For any Date object `d` whose milliseconds amount is zero, the result of `Date.parse(d.toString())` is equal to `d.valueOf()`. See <emu-xref href="#sec-date.parse"></emu-xref>.</p>
<p>For any Date object `d` whose milliseconds amount is 0, the result of `Date.parse(d.toString())` is equal to `d.valueOf()`. See <emu-xref href="#sec-date.parse"></emu-xref>.</p>
</emu-note>
<emu-note>
<p>The `toString` function is intentionally generic; it does not require that its *this* value be a Date object. Therefore, it can be transferred to other kinds of objects for use as a method.</p>
Expand Down Expand Up @@ -28158,7 +28158,7 @@ <h1>String.raw ( _template_, ..._substitutions_ )</h1>
1. Let _cooked_ be ? ToObject(_template_).
1. Let _raw_ be ? ToObject(? Get(_cooked_, `"raw"`)).
1. Let _literalSegments_ be ? ToLength(? Get(_raw_, `"length"`)).
1. If _literalSegments_ &le; 0, return the empty string.
1. If _literalSegments_ is 0, return the empty string.
1. Let _stringElements_ be a new empty List.
1. Let _nextIndex_ be 0.
1. Repeat,
Expand Down Expand Up @@ -29793,10 +29793,10 @@ <h1>Term</h1>
<h1>Runtime Semantics: RepeatMatcher ( _m_, _min_, _max_, _greedy_, _x_, _c_, _parenIndex_, _parenCount_ )</h1>
<p>The abstract operation RepeatMatcher takes eight parameters, a Matcher _m_, an integer _min_, an integer (or &infin;) _max_, a Boolean _greedy_, a State _x_, a Continuation _c_, an integer _parenIndex_, and an integer _parenCount_, and performs the following steps:</p>
<emu-alg>
1. If _max_ is zero, return _c_(_x_).
1. If _max_ is 0, return _c_(_x_).
1. Let _d_ be an internal Continuation closure that takes one State argument _y_ and performs the following steps when evaluated:
1. If _min_ is zero and _y_'s _endIndex_ is equal to _x_'s _endIndex_, return ~failure~.
1. If _min_ is zero, let _min2_ be zero; otherwise let _min2_ be _min_-1.
1. If _min_ is 0 and _y_'s _endIndex_ is equal to _x_'s _endIndex_, return ~failure~.
1. If _min_ is 0, let _min2_ be zero; otherwise let _min2_ be _min_-1.
1. If _max_ is &infin;, let _max2_ be &infin;; otherwise let _max2_ be _max_-1.
1. Call RepeatMatcher(_m_, _min2_, _max2_, _greedy_, _y_, _c_, _parenIndex_, _parenCount_) and return its result.
1. Let _cap_ be a copy of _x_'s _captures_ List.
Expand Down Expand Up @@ -29862,7 +29862,7 @@ <h1>Assertion</h1>
<emu-alg>
1. Return an internal AssertionTester closure that takes a State argument _x_ and performs the following steps when evaluated:
1. Let _e_ be _x_'s _endIndex_.
1. If _e_ is zero, return *true*.
1. If _e_ is 0, return *true*.
1. If _Multiline_ is *false*, return *false*.
1. If the character _Input_[_e_-1] is one of |LineTerminator|, return *true*.
1. Return *false*.
Expand Down Expand Up @@ -32043,7 +32043,7 @@ <h1>Array.prototype.pop ( )</h1>
<emu-alg>
1. Let _O_ be ? ToObject(*this* value).
1. Let _len_ be ? ToLength(? Get(_O_, `"length"`)).
1. If _len_ is zero, then
1. If _len_ is 0, then
1. Perform ? Set(_O_, `"length"`, 0, *true*).
1. Return *undefined*.
1. Else _len_ &gt; 0,
Expand Down Expand Up @@ -32220,7 +32220,7 @@ <h1>Array.prototype.shift ( )</h1>
<emu-alg>
1. Let _O_ be ? ToObject(*this* value).
1. Let _len_ be ? ToLength(? Get(_O_, `"length"`)).
1. If _len_ is zero, then
1. If _len_ is 0, then
1. Perform ? Set(_O_, `"length"`, 0, *true*).
1. Return *undefined*.
1. Let _first_ be ? Get(_O_, `"0"`).
Expand Down

0 comments on commit c18b758

Please sign in to comment.