Hyperlinkv0.8.0-beta.28

BigInt

BigInt.maxconsteffect/BigInt.ts:551
(that: bigint): (self: bigint) => bigint
(self: bigint, that: bigint): bigint

Returns the maximum between two bigints.

When to use

Use to select the larger of two bigint values.

Example (Finding the maximum bigint)

import { BigInt } from "effect"
import * as assert from "node:assert"

assert.deepStrictEqual(BigInt.max(2n, 3n), 3n)
mathmin
Source effect/BigInt.ts:5514 lines
export const max: {
  (that: bigint): (self: bigint) => bigint
  (self: bigint, that: bigint): bigint
} = order.max(Order)