Server IP : 162.213.251.212 / Your IP : 18.226.34.241 [ Web Server : LiteSpeed System : Linux business55.web-hosting.com 4.18.0-553.lve.el8.x86_64 #1 SMP Mon May 27 15:27:34 UTC 2024 x86_64 User : allssztx ( 535) PHP Version : 8.1.31 Disable Function : NONE Domains : 1 Domains MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : OFF | Pkexec : OFF Directory : /home/allssztx/www/easybuyer/node_modules/es-abstract/2018/ |
Upload File : |
'use strict'; var GetIntrinsic = require('get-intrinsic'); var has = require('has'); var $TypeError = GetIntrinsic('%TypeError%'); var getSymbolDescription = require('get-symbol-description'); var DefinePropertyOrThrow = require('./DefinePropertyOrThrow'); var IsExtensible = require('./IsExtensible'); var Type = require('./Type'); // https://ecma-international.org/ecma-262/6.0/#sec-setfunctionname module.exports = function SetFunctionName(F, name) { if (typeof F !== 'function') { throw new $TypeError('Assertion failed: `F` must be a function'); } if (!IsExtensible(F) || has(F, 'name')) { throw new $TypeError('Assertion failed: `F` must be extensible, and must not have a `name` own property'); } var nameType = Type(name); if (nameType !== 'Symbol' && nameType !== 'String') { throw new $TypeError('Assertion failed: `name` must be a Symbol or a String'); } if (nameType === 'Symbol') { var description = getSymbolDescription(name); // eslint-disable-next-line no-param-reassign name = typeof description === 'undefined' ? '' : '[' + description + ']'; } if (arguments.length > 2) { var prefix = arguments[2]; // eslint-disable-next-line no-param-reassign name = prefix + ' ' + name; } return DefinePropertyOrThrow(F, 'name', { '[[Value]]': name, '[[Writable]]': false, '[[Enumerable]]': false, '[[Configurable]]': true }); };