{"ast":null,"code":"'use strict';\n\nvar GetIntrinsic = require('get-intrinsic');\nvar callBound = require('call-bound');\nvar $WeakSet = GetIntrinsic('%WeakSet%', true);\n\n/** @type {undefined | ((thisArg: Set, value: V) => boolean)} */\nvar $setHas = callBound('WeakSet.prototype.has', true);\nif ($setHas) {\n /** @type {undefined | ((thisArg: WeakMap, key: K) => boolean)} */\n var $mapHas = callBound('WeakMap.prototype.has', true);\n\n /** @type {import('.')} */\n module.exports = function isWeakSet(x) {\n if (!x || typeof x !== 'object') {\n return false;\n }\n try {\n // @ts-expect-error TS can't figure out that $setHas is always truthy here\n $setHas(x, $setHas);\n if ($mapHas) {\n try {\n // @ts-expect-error this indeed might not be a weak collection\n $mapHas(x, $mapHas);\n } catch (e) {\n return true;\n }\n }\n // @ts-expect-error TS can't figure out that $WeakSet is always truthy here\n return x instanceof $WeakSet; // core-js workaround, pre-v3\n } catch (e) {}\n return false;\n };\n} else {\n /** @type {import('.')} */\n // @ts-expect-error\n module.exports = function isWeakSet(x) {\n // eslint-disable-line no-unused-vars\n // `WeakSet` does not exist, or does not have a `has` method\n return false;\n };\n}","map":{"version":3,"names":["GetIntrinsic","require","callBound","$WeakSet","$setHas","$mapHas","module","exports","isWeakSet","x","e"],"sources":["/Users/max_liu/max_liu/company/tools_auto_pt/node_modules/is-weakset/index.js"],"sourcesContent":["'use strict';\n\nvar GetIntrinsic = require('get-intrinsic');\nvar callBound = require('call-bound');\n\nvar $WeakSet = GetIntrinsic('%WeakSet%', true);\n\n/** @type {undefined | ((thisArg: Set, value: V) => boolean)} */\nvar $setHas = callBound('WeakSet.prototype.has', true);\n\nif ($setHas) {\n\t/** @type {undefined | ((thisArg: WeakMap, key: K) => boolean)} */\n\tvar $mapHas = callBound('WeakMap.prototype.has', true);\n\n\t/** @type {import('.')} */\n\tmodule.exports = function isWeakSet(x) {\n\t\tif (!x || typeof x !== 'object') {\n\t\t\treturn false;\n\t\t}\n\t\ttry {\n\t\t\t// @ts-expect-error TS can't figure out that $setHas is always truthy here\n\t\t\t$setHas(x, $setHas);\n\t\t\tif ($mapHas) {\n\t\t\t\ttry {\n\t\t\t\t\t// @ts-expect-error this indeed might not be a weak collection\n\t\t\t\t\t$mapHas(x, $mapHas);\n\t\t\t\t} catch (e) {\n\t\t\t\t\treturn true;\n\t\t\t\t}\n\t\t\t}\n\t\t\t// @ts-expect-error TS can't figure out that $WeakSet is always truthy here\n\t\t\treturn x instanceof $WeakSet; // core-js workaround, pre-v3\n\t\t} catch (e) {}\n\t\treturn false;\n\t};\n} else {\n\t/** @type {import('.')} */\n\t// @ts-expect-error\n\tmodule.exports = function isWeakSet(x) { // eslint-disable-line no-unused-vars\n\t\t// `WeakSet` does not exist, or does not have a `has` method\n\t\treturn false;\n\t};\n}\n"],"mappings":"AAAA,YAAY;;AAEZ,IAAIA,YAAY,GAAGC,OAAO,CAAC,eAAe,CAAC;AAC3C,IAAIC,SAAS,GAAGD,OAAO,CAAC,YAAY,CAAC;AAErC,IAAIE,QAAQ,GAAGH,YAAY,CAAC,WAAW,EAAE,IAAI,CAAC;;AAE9C;AACA,IAAII,OAAO,GAAGF,SAAS,CAAC,uBAAuB,EAAE,IAAI,CAAC;AAEtD,IAAIE,OAAO,EAAE;EACZ;EACA,IAAIC,OAAO,GAAGH,SAAS,CAAC,uBAAuB,EAAE,IAAI,CAAC;;EAEtD;EACAI,MAAM,CAACC,OAAO,GAAG,SAASC,SAASA,CAACC,CAAC,EAAE;IACtC,IAAI,CAACA,CAAC,IAAI,OAAOA,CAAC,KAAK,QAAQ,EAAE;MAChC,OAAO,KAAK;IACb;IACA,IAAI;MACH;MACAL,OAAO,CAACK,CAAC,EAAEL,OAAO,CAAC;MACnB,IAAIC,OAAO,EAAE;QACZ,IAAI;UACH;UACAA,OAAO,CAACI,CAAC,EAAEJ,OAAO,CAAC;QACpB,CAAC,CAAC,OAAOK,CAAC,EAAE;UACX,OAAO,IAAI;QACZ;MACD;MACA;MACA,OAAOD,CAAC,YAAYN,QAAQ,CAAC,CAAC;IAC/B,CAAC,CAAC,OAAOO,CAAC,EAAE,CAAC;IACb,OAAO,KAAK;EACb,CAAC;AACF,CAAC,MAAM;EACN;EACA;EACAJ,MAAM,CAACC,OAAO,GAAG,SAASC,SAASA,CAACC,CAAC,EAAE;IAAE;IACxC;IACA,OAAO,KAAK;EACb,CAAC;AACF","ignoreList":[]},"metadata":{},"sourceType":"script","externalDependencies":[]}