amis-rpc-design/node_modules/core-js-pure/internals/a-map.js
2023-10-07 19:42:30 +08:00

9 lines
349 B
JavaScript

'use strict';
var tryToString = require('../internals/try-to-string');
// Perform ? RequireInternalSlot(M, [[MapData]])
module.exports = function (it) {
if (typeof it == 'object' && 'size' in it && 'has' in it && 'get' in it && 'set' in it && 'delete' in it && 'entries' in it) return it;
throw TypeError(tryToString(it) + ' is not a map');
};