1 export * from 'pmcrypto-v6-canary/lib/bigInteger';
4 * Get this value as an exact Number (max 53 bits)
5 * Fails if this value is too large
6 * @throws if input is larger than `Number.MAX_SAFE_INTEGER`
8 export function bigIntToNumber(x: bigint) {
9 if (x > BigInt(Number.MAX_SAFE_INTEGER)) {
10 throw new Error('Number can only safely store up to 53 bits');