Urara-Blog/node_modules/.pnpm-store/v3/files/b9/54464f9c785c4f4ebc5bef9b805c19ad3e68a4f834acf976b3b175357978ee93466418b7f01b164981986408e75450b8edd9f2bdbdc042d6aa9d9faedae935
2022-08-14 01:14:53 +08:00

18 lines
427 B
Text

'use strict';
var GetIntrinsic = require('get-intrinsic');
var $String = GetIntrinsic('%String%');
var $TypeError = GetIntrinsic('%TypeError%');
var Type = require('../Type');
// https://262.ecma-international.org/11.0/#sec-numeric-types-bigint-tostring
module.exports = function BigIntToString(x) {
if (Type(x) !== 'BigInt') {
throw new $TypeError('Assertion failed: `x` must be a BigInt');
}
return $String(x);
};