From ccbb91e5fe8c901645560aff88cb0c0a93c5c031 Mon Sep 17 00:00:00 2001 From: Philip Chimento Date: Mon, 16 Feb 2026 11:13:07 -0800 Subject: [PATCH 01/20] Normative: Temporal stage 4, part 1 This commit makes changes to ECMA-262 AOs that are needed for Temporal regardless of whether it lands in a separate document. --- spec.html | 678 ++++++++++++++++++++++++++++++++++++++++++++++-------- 1 file changed, 585 insertions(+), 93 deletions(-) diff --git a/spec.html b/spec.html index fe44410f4b..f824a954de 100644 --- a/spec.html +++ b/spec.html @@ -1181,13 +1181,14 @@

Mathematical Operations

The mathematical function ln(_x_) produces the natural logarithm of _x_. The mathematical function log10(_x_) produces the base 10 logarithm of _x_. The mathematical function log2(_x_) produces the base 2 logarithm of _x_.

The mathematical function min(_x1_, _x2_, … , _xN_) produces the mathematically smallest of _x1_ through _xN_. The mathematical function max(_x1_, _x2_, ..., _xN_) produces the mathematically largest of _x1_ through _xN_. The domain and range of these mathematical functions are the extended mathematical values.

The notation “_x_ modulo _y_” (_y_ must be finite and non-zero) computes a value _k_ of the same sign as _y_ (or zero) such that abs(_k_) < abs(_y_) and _x_ - _k_ = _q_ × _y_ for some integer _q_.

+

The mathematical function remainder(_x_, _y_) produces the mathematical value whose sign is the sign of _x_ and whose magnitude is abs(_x_) modulo _y_.

The phrase "the result of clamping _x_ between _lower_ and _upper_" (where _x_ is an extended mathematical value and _lower_ and _upper_ are mathematical values such that _lower_ ≤ _upper_) produces _lower_ if _x_ < _lower_, produces _upper_ if _x_ > _upper_, and otherwise produces _x_.

The mathematical function floor(_x_) produces the largest integer (closest to +∞) that is not larger than _x_.

floor(_x_) = _x_ - (_x_ modulo 1).

The mathematical function truncate(_x_) removes the fractional part of _x_ by rounding towards zero, producing -floor(-_x_) if _x_ < 0 and otherwise producing floor(_x_).

-

Mathematical functions min, max, abs, floor, and truncate are not defined for Numbers and BigInts, and any usage of those methods that have non-mathematical value arguments would be an editorial error in this specification.

+

Mathematical functions min, max, abs, remainder, floor, and truncate are not defined for Numbers and BigInts, and any usage of those methods that have non-mathematical value arguments would be an editorial error in this specification.

An interval from lower bound _a_ to upper bound _b_ is a possibly-infinite, possibly-empty set of numeric values of the same numeric type. Each bound will be described as either inclusive or exclusive, but not both. There are four kinds of intervals, as follows: