Skip to content

Commit

Permalink
Editorial: Make implementation-defined language more concise
Browse files Browse the repository at this point in the history
Ms2ger pointed out that "the value of" is unnecessary here.
  • Loading branch information
ptomato committed Sep 2, 2021
1 parent 6178ed3 commit 42c964e
Showing 1 changed file with 20 additions and 20 deletions.
40 changes: 20 additions & 20 deletions spec/intl.html
Original file line number Diff line number Diff line change
Expand Up @@ -1206,7 +1206,7 @@ <h1>Temporal.Calendar.prototype.dateFromFields ( _fields_ [ , _options_ ] )</h1>
1. Else,
1. Let _overflow_ be ? ToTemporalOverflow(_options_).
1. Set _fields_ to ? PrepareTemporalFields(_fields_, « *"day"*, *"era"*, *"eraYear"*, *"month"*, *"monthCode"*, *"year"* », « *"day"* »).
1. Let _result_ be a Record with [[Year]], [[Month]], and [[Day]] fields, that is the result of implementation-defined processing of _fields_, _overflow_, and the value of _calendar_.[[Identifier]].
1. Let _result_ be a Record with [[Year]], [[Month]], and [[Day]] fields, that is the result of implementation-defined processing of _fields_, _overflow_, and _calendar_.[[Identifier]].
1. Return ? CreateTemporalDate(_result_.[[Year]], _result_.[[Month]], _result_.[[Day]], _calendar_).
</emu-alg>
</emu-clause>
Expand All @@ -1227,7 +1227,7 @@ <h1>Temporal.Calendar.prototype.yearMonthFromFields ( _fields_ [ , _options_ ] )
1. Else,
1. Let _overflow_ be ? ToTemporalOverflow(_options_).
1. Set _fields_ to ? PrepareTemporalFields(_fields_, « *"era"*, *"eraYear"*, *"month"*, *"monthCode"*, *"year"* », « »).
1. Let _result_ be a Record with [[Year]], [[Month]], and [[ReferenceISODay]] integer fields, that is the result of implementation-defined processing of _fields_, _overflow_, and the value of _calendar_.[[Identifier]].
1. Let _result_ be a Record with [[Year]], [[Month]], and [[ReferenceISODay]] integer fields, that is the result of implementation-defined processing of _fields_, _overflow_, and _calendar_.[[Identifier]].
1. Return ? CreateTemporalYearMonth(_result_.[[Year]], _result_.[[Month]], _calendar_, _result_.[[ReferenceISODay]]).
</emu-alg>
</emu-clause>
Expand All @@ -1248,7 +1248,7 @@ <h1>Temporal.Calendar.prototype.monthDayFromFields ( _fields_ [ , _options_ ] )<
1. Else,
1. Set _fields_ to ? PrepareTemporalFields(_fields_, « *"day"*, *"era"*, *"eraYear"*, *"month"*, *"monthCode"*, *"year"* », « *"day"* »).
1. Let _overflow_ be ? ToTemporalOverflow(_options_).
1. Let _result_ be a Record with [[Month]], [[Day]], and [[ReferenceISOYear]] fields, that is the result of implementation-defined processing of _fields_, _overflow_, and the value of _calendar_.[[Identifier]].
1. Let _result_ be a Record with [[Month]], [[Day]], and [[ReferenceISOYear]] fields, that is the result of implementation-defined processing of _fields_, _overflow_, and _calendar_.[[Identifier]].
1. Return ? CreateTemporalMonthDay(_result_.[[Month]], _result_.[[Day]], _calendar_, _result_.[[ReferenceISOYear]]).
</emu-alg>
</emu-clause>
Expand Down Expand Up @@ -1292,7 +1292,7 @@ <h1>Temporal.Calendar.prototype.dateUntil ( _one_, _two_ [ , _options_ ] )</h1>
1. If _calendar_.[[Identifier]] is *"iso8601"*, then
1. Let _result_ be ! DifferenceISODate(_one_.[[ISOYear]], _one_.[[ISOMonth]], _one_.[[ISODay]], _two_.[[ISOYear]], _two_.[[ISOMonth]], _two_.[[ISODay]], _largestUnit_).
1. Else,
1. Let _result_ be a Record with [[Years]], [[Months]], [[Weeks]], and [[Days]] fields, that is the result of implementation-defined processing of _one_, _two_, _largestUnit_, and the value of _calendar_.[[Identifier]].
1. Let _result_ be a Record with [[Years]], [[Months]], [[Weeks]], and [[Days]] fields, that is the result of implementation-defined processing of _one_, _two_, _largestUnit_, and _calendar_.[[Identifier]].
1. Return ? CreateTemporalDuration(_result_.[[Years]], _result_.[[Months]], _result_.[[Weeks]], _result_.[[Days]], 0, 0, 0, 0, 0, 0).
</emu-alg>
</emu-clause>
Expand All @@ -1310,7 +1310,7 @@ <h1>Temporal.Calendar.prototype.era ( _temporalDateLike_ )</h1>
1. Set _temporalDateLike_ to ? ToTemporalDate(_temporalDateLike_).
1. If _calendar_.[[Identifier]] is *"iso8601"*, then
1. Return *undefined*.
1. Let _era_ be the result of implementation-defined processing of _temporalDateLike_ and the value of _calendar_.[[Identifier]].
1. Let _era_ be the result of implementation-defined processing of _temporalDateLike_ and _calendar_.[[Identifier]].
1. Return _era_.
</emu-alg>
</emu-clause>
Expand All @@ -1328,7 +1328,7 @@ <h1>Temporal.Calendar.prototype.eraYear ( _temporalDateLike_ )</h1>
1. Set _temporalDateLike_ to ? ToTemporalDate(_temporalDateLike_).
1. If _calendar_.[[Identifier]] is *"iso8601"*, then
1. Return *undefined*.
1. Let _eraYear_ be the result of implementation-defined processing of _temporalDateLike_ and the value of _calendar_.[[Identifier]].
1. Let _eraYear_ be the result of implementation-defined processing of _temporalDateLike_ and _calendar_.[[Identifier]].
1. Return 𝔽(_eraYear_).
</emu-alg>
</emu-clause>
Expand All @@ -1348,7 +1348,7 @@ <h1>Temporal.Calendar.prototype.year ( _temporalDateLike_ )</h1>
1. If _calendar_.[[Identifier]] is *"iso8601"*, then
1. Let _year_ be ! ISOYear(_temporalDateLike_).
1. Else,
1. Let _year_ be the result of implementation-defined processing of _temporalDateLike_ and the value of _calendar_.[[Identifier]].
1. Let _year_ be the result of implementation-defined processing of _temporalDateLike_ and _calendar_.[[Identifier]].
1. Return 𝔽(_year_).
</emu-alg>
</emu-clause>
Expand All @@ -1370,7 +1370,7 @@ <h1>Temporal.Calendar.prototype.month ( _temporalDateLike_ )</h1>
1. If _calendar_.[[Identifier]] is *"iso8601"*, then
1. Let _month_ be ! ISOMonth(_temporalDateLike_).
1. Else,
1. Let _month_ be the result of implementation-defined processing of _temporalDateLike_ and the value of _calendar_.[[Identifier]].
1. Let _month_ be the result of implementation-defined processing of _temporalDateLike_ and _calendar_.[[Identifier]].
1. Return 𝔽(_month_).
</emu-alg>
</emu-clause>
Expand All @@ -1390,7 +1390,7 @@ <h1>Temporal.Calendar.prototype.monthCode ( _temporalDateLike_ )</h1>
1. If _calendar_.[[Identifier]] is *"iso8601"*, then
1. Let _monthCode_ be ! ISOMonthCode(_temporalDateLike_).
1. Else,
1. Let _monthCode_ be the result of implementation-defined processing of _temporalDateLike_ and the value of _calendar_.[[Identifier]].
1. Let _monthCode_ be the result of implementation-defined processing of _temporalDateLike_ and _calendar_.[[Identifier]].
1. Return _monthCode_.
</emu-alg>
</emu-clause>
Expand All @@ -1410,7 +1410,7 @@ <h1>Temporal.Calendar.prototype.day ( _temporalDateLike_ )</h1>
1. If _calendar_.[[Identifier]] is *"iso8601"*, then
1. Let _day_ be ! ISODay(_temporalDateLike_).
1. Else,
1. Let _day_ be the result of implementation-defined processing of _temporalDateLike_ and the value of _calendar_.[[Identifier]].
1. Let _day_ be the result of implementation-defined processing of _temporalDateLike_ and _calendar_.[[Identifier]].
1. Return 𝔽(_day_).
</emu-alg>
</emu-clause>
Expand All @@ -1429,7 +1429,7 @@ <h1>Temporal.Calendar.prototype.dayOfWeek ( _dateOrDateTime_ )</h1>
1. If _calendar_.[[Identifier]] is *"iso8601"*, then
1. Let _dayOfWeek_ be ! ToISODayOfWeek(_temporalDate_.[[ISOYear]], _temporalDate_.[[ISOMonth]], _temporalDate_.[[ISODay]]).
1. Else,
1. Let _dayOfWeek_ be the result of implementation-defined processing of _temporalDate_ and the value of _calendar_.[[Identifier]].
1. Let _dayOfWeek_ be the result of implementation-defined processing of _temporalDate_ and _calendar_.[[Identifier]].
1. Return 𝔽(_dayOfWeek_).
</emu-alg>
</emu-clause>
Expand All @@ -1448,7 +1448,7 @@ <h1>Temporal.Calendar.prototype.dayOfYear ( _temporalDateLike_ )</h1>
1. If _calendar_.[[Identifier]] is *"iso8601"*, then
1. Let _dayOfYear_ be ! ToISODayOfYear(_temporalDate_.[[ISOYear]], _temporalDate_.[[ISOMonth]], _temporalDate_.[[ISODay]]).
1. Else,
1. Let _dayOfYear_ be the result of implementation-defined processing of _temporalDate_ and the value of _calendar_.[[Identifier]].
1. Let _dayOfYear_ be the result of implementation-defined processing of _temporalDate_ and _calendar_.[[Identifier]].
1. Return 𝔽(_dayOfYear_).
</emu-alg>
</emu-clause>
Expand All @@ -1467,7 +1467,7 @@ <h1>Temporal.Calendar.prototype.weekOfYear ( _temporalDateLike_ )</h1>
1. If _calendar_.[[Identifier]] is *"iso8601"*, then
1. Let _weekOfYear_ be ! ToISOWeekOfYear(_temporalDate_.[[ISOYear]], _temporalDate_.[[ISOMonth]], _temporalDate_.[[ISODay]]).
1. Else,
1. Let _weekOfYear_ be the result of implementation-defined processing of _temporalDate_ and the value of _calendar_.[[Identifier]].
1. Let _weekOfYear_ be the result of implementation-defined processing of _temporalDate_ and _calendar_.[[Identifier]].
1. Return 𝔽(_weekOfYear_).
</emu-alg>
</emu-clause>
Expand All @@ -1486,7 +1486,7 @@ <h1>Temporal.Calendar.prototype.daysInWeek ( _temporalDateLike_ )</h1>
1. If _calendar_.[[Identifier]] is *"iso8601"*, then
1. Let _daysInWeek_ be 7.
1. Else,
1. Let _daysInWeek_ be the result of implementation-defined processing of _temporalDate_ and the value of _calendar_.[[Identifier]].
1. Let _daysInWeek_ be the result of implementation-defined processing of _temporalDate_ and _calendar_.[[Identifier]].
1. Return 𝔽(_daysInWeek_).
</emu-alg>
</emu-clause>
Expand All @@ -1506,7 +1506,7 @@ <h1>Temporal.Calendar.prototype.daysInMonth ( _temporalDateLike_ )</h1>
1. If _calendar_.[[Identifier]] is *"iso8601"*, then
1. Let _daysInMonth_ be ! ISODaysInMonth(_temporalDateLike_.[[ISOYear]], _temporalDateLike_.[[ISOMonth]]).
1. Else,
1. Let _daysInMonth_ be the result of implementation-defined processing of _temporalDateLike_ and the value of _calendar_.[[Identifier]].
1. Let _daysInMonth_ be the result of implementation-defined processing of _temporalDateLike_ and _calendar_.[[Identifier]].
1. Return 𝔽(_daysInMonth_).
</emu-alg>
</emu-clause>
Expand All @@ -1526,7 +1526,7 @@ <h1>Temporal.Calendar.prototype.daysInYear ( _temporalDateLike_ )</h1>
1. If _calendar_.[[Identifier]] is *"iso8601"*, then
1. Let _daysInYear_ be ! ISODaysInYear(_temporalDateLike_.[[ISOYear]]).
1. Else,
1. Let _daysInYear_ be the result of implementation-defined processing of _temporalDateLike_ and the value of _calendar_.[[Identifier]].
1. Let _daysInYear_ be the result of implementation-defined processing of _temporalDateLike_ and _calendar_.[[Identifier]].
1. Return 𝔽(_daysInYear_).
</emu-alg>
</emu-clause>
Expand All @@ -1546,7 +1546,7 @@ <h1>Temporal.Calendar.prototype.monthsInYear ( _temporalDateLike_ )</h1>
1. If _calendar_.[[Identifier]] is *"iso8601"*, then
1. Let _monthsInYear_ be 12.
1. Else,
1. Let _monthsInYear_ be the result of implementation-defined processing of _temporalDateLike_ and the value of _calendar_.[[Identifier]].
1. Let _monthsInYear_ be the result of implementation-defined processing of _temporalDateLike_ and _calendar_.[[Identifier]].
1. Return 𝔽(_monthsInYear_).
</emu-alg>
</emu-clause>
Expand All @@ -1566,7 +1566,7 @@ <h1>Temporal.Calendar.prototype.inLeapYear ( _temporalDateLike_ )</h1>
1. If _calendar_.[[Identifier]] is *"iso8601"*, then
1. Let _inLeapYear_ be ! IsISOLeapYear(_temporalDateLike_.[[ISOYear]]).
1. Else,
1. Let _inLeapYear_ be the result of implementation-defined processing of _temporalDateLike_ and the value of _calendar_.[[Identifier]].
1. Let _inLeapYear_ be the result of implementation-defined processing of _temporalDateLike_ and _calendar_.[[Identifier]].
1. Return _inLeapYear_.
</emu-alg>
</emu-clause>
Expand Down Expand Up @@ -1601,7 +1601,7 @@ <h1>Temporal.Calendar.prototype.fields ( _fields_ )</h1>
1. If _calendar_.[[Identifier]] is *"iso8601"*, then
1. Let _result_ be _fieldNames_.
1. Else,
1. Let _result_ be the result of implementation-defined processing of _fieldNames_ and the value of _calendar_.[[Identifier]].
1. Let _result_ be the result of implementation-defined processing of _fieldNames_ and _calendar_.[[Identifier]].
1. Return ! CreateArrayFromList(_result_).
</emu-alg>
</emu-clause>
Expand Down Expand Up @@ -1632,7 +1632,7 @@ <h1>Temporal.Calendar.prototype.mergeFields ( _fields_, _additionalFields_ )</h1
1. Let _propValue_ be ? Get(_additionalFields_, _key_).
1. If _propValue_ is not *undefined*, then
1. Perform ! CreateDataPropertyOrThrow(_additionalFieldsCopied_, _key_, _propValue_).
1. Return the result of implementation-defined processing of _fieldsCopied_, _additionalFieldsCopied_, and the value of _calendar_.[[Identifier]].
1. Return the result of implementation-defined processing of _fieldsCopied_, _additionalFieldsCopied_, and _calendar_.[[Identifier]].
</emu-alg>
</emu-clause>
</emu-clause>
Expand Down

0 comments on commit 42c964e

Please sign in to comment.