ECMA-262 in Lean

Spec issues · no erratum · docs/spec-issues/28-tobigint-boolean-literals.md

28. ToBigInt: the Boolean row writes its results as source-text literals and its cases as one sentence

Location
§7.1.15 ToBigInt (#sec-tobigint), the BigInt Conversions table (#table-tobigint), the Boolean row.
Kind
editorial (notation).
Model erratum
none: the model reads `1n` as a BigInt literal and the sentence as a value by two cases, so the change below alters no result.
Upstream
Checked 2026-11-19: none found (searched for "ToBigInt" with Boolean).

Text

| Boolean | Return 1n if primitive is true and 0n if primitive is false. |

Why it is irregular

Proposed wording

--- a/spec.html
+++ b/spec.html
@@ -5260,6 +5260,6 @@
               Boolean
             </td>
             <td>
-              Return `1n` if _primitive_ is *true* and `0n` if _primitive_ is *false*.
+              If _primitive_ is *true*, return *1*<sub>ℤ</sub>. Otherwise, return *0*<sub>ℤ</sub>.
             </td>
           </tr>

or, in the table's one-sentence style: "Return 1ℤ if primitive is true; otherwise return 0ℤ."