(name, nativeFactory, shimFactory)
| 336 | ts.Set = getCollectionImplementation("Set", "tryGetNativeSet", "createSetShim"); |
| 337 | /* @internal */ |
| 338 | function getCollectionImplementation(name, nativeFactory, shimFactory) { |
| 339 | var _a; |
| 340 | // NOTE: ts.ShimCollections will be defined for typescriptServices.js but not for tsc.js, so we must test for it. |
| 341 | var constructor = (_a = NativeCollections[nativeFactory]()) !== null && _a !== void 0 ? _a : ts.ShimCollections === null || ts.ShimCollections === void 0 ? void 0 : ts.ShimCollections[shimFactory](ts.getIterator); |
| 342 | if (constructor) |
| 343 | return constructor; |
| 344 | throw new Error("TypeScript requires an environment that provides a compatible native ".concat(name, " implementation.")); |
| 345 | } |
| 346 | })(ts || (ts = {})); |
| 347 | /* @internal */ |
| 348 | var ts; |
no test coverage detected
searching dependent graphs…