@nubjs/nub-win32-arm64 0.0.7 → 0.0.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bin/nub.exe +0 -0
- package/package.json +1 -1
- package/runtime/addons/nub-native.node +0 -0
- package/runtime/node_modules/@js-temporal/polyfill/CHANGELOG.md +453 -0
- package/runtime/node_modules/@js-temporal/polyfill/LICENSE +13 -0
- package/runtime/node_modules/@js-temporal/polyfill/README.md +90 -0
- package/runtime/node_modules/@js-temporal/polyfill/dist/index.cjs +2 -0
- package/runtime/node_modules/@js-temporal/polyfill/dist/index.cjs.map +1 -0
- package/runtime/node_modules/@js-temporal/polyfill/dist/index.esm.js +2 -0
- package/runtime/node_modules/@js-temporal/polyfill/dist/index.esm.js.map +1 -0
- package/runtime/node_modules/@js-temporal/polyfill/dist/index.umd.js +2 -0
- package/runtime/node_modules/@js-temporal/polyfill/dist/index.umd.js.map +1 -0
- package/runtime/node_modules/@js-temporal/polyfill/index.d.cts +1215 -0
- package/runtime/node_modules/@js-temporal/polyfill/index.d.ts +1215 -0
- package/runtime/node_modules/@js-temporal/polyfill/lib/assert.ts +8 -0
- package/runtime/node_modules/@js-temporal/polyfill/lib/bigintmath.ts +39 -0
- package/runtime/node_modules/@js-temporal/polyfill/lib/calendar.ts +2424 -0
- package/runtime/node_modules/@js-temporal/polyfill/lib/debug.ts +7 -0
- package/runtime/node_modules/@js-temporal/polyfill/lib/duration.ts +438 -0
- package/runtime/node_modules/@js-temporal/polyfill/lib/durationformat.d.ts +93 -0
- package/runtime/node_modules/@js-temporal/polyfill/lib/ecmascript.ts +4973 -0
- package/runtime/node_modules/@js-temporal/polyfill/lib/index.ts +34 -0
- package/runtime/node_modules/@js-temporal/polyfill/lib/init.ts +43 -0
- package/runtime/node_modules/@js-temporal/polyfill/lib/instant.ts +138 -0
- package/runtime/node_modules/@js-temporal/polyfill/lib/internaltypes.d.ts +242 -0
- package/runtime/node_modules/@js-temporal/polyfill/lib/intl.ts +758 -0
- package/runtime/node_modules/@js-temporal/polyfill/lib/intrinsicclass.ts +162 -0
- package/runtime/node_modules/@js-temporal/polyfill/lib/legacydate.ts +17 -0
- package/runtime/node_modules/@js-temporal/polyfill/lib/math.ts +96 -0
- package/runtime/node_modules/@js-temporal/polyfill/lib/now.ts +48 -0
- package/runtime/node_modules/@js-temporal/polyfill/lib/plaindate.ts +212 -0
- package/runtime/node_modules/@js-temporal/polyfill/lib/plaindatetime.ts +274 -0
- package/runtime/node_modules/@js-temporal/polyfill/lib/plainmonthday.ts +110 -0
- package/runtime/node_modules/@js-temporal/polyfill/lib/plaintime.ts +154 -0
- package/runtime/node_modules/@js-temporal/polyfill/lib/plainyearmonth.ts +157 -0
- package/runtime/node_modules/@js-temporal/polyfill/lib/regex.ts +59 -0
- package/runtime/node_modules/@js-temporal/polyfill/lib/slots.ts +341 -0
- package/runtime/node_modules/@js-temporal/polyfill/lib/temporal.ts +10 -0
- package/runtime/node_modules/@js-temporal/polyfill/lib/timeduration.ts +149 -0
- package/runtime/node_modules/@js-temporal/polyfill/lib/zoneddatetime.ts +492 -0
- package/runtime/node_modules/@js-temporal/polyfill/package.json +143 -0
- package/runtime/node_modules/@oxc-parser/binding-win32-x64-msvc/README.md +3 -0
- package/runtime/node_modules/@oxc-parser/binding-win32-x64-msvc/package.json +39 -0
- package/runtime/node_modules/@oxc-parser/binding-win32-x64-msvc/parser.win32-x64-msvc.node +0 -0
- package/runtime/node_modules/@oxc-project/runtime/CHANGELOG.md +88 -0
- package/runtime/node_modules/@oxc-project/runtime/LICENSE +22 -0
- package/runtime/node_modules/@oxc-project/runtime/README.md +5 -0
- package/runtime/node_modules/@oxc-project/runtime/package.json +1066 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/AwaitValue.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/OverloadYield.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/applyDecoratedDescriptor.js +9 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/applyDecs.js +236 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/applyDecs2203.js +184 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/applyDecs2203R.js +191 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/applyDecs2301.js +222 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/applyDecs2305.js +133 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/applyDecs2311.js +124 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/arrayLikeToArray.js +6 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/arrayWithHoles.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/arrayWithoutHoles.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/assertClassBrand.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/assertThisInitialized.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/asyncGeneratorDelegate.js +24 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/asyncIterator.js +45 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/asyncToGenerator.js +26 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/awaitAsyncGenerator.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/callSuper.js +7 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/checkInRHS.js +6 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/checkPrivateRedeclaration.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/classApplyDescriptorDestructureSet.js +10 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/classApplyDescriptorGet.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/classApplyDescriptorSet.js +7 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/classCallCheck.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/classCheckPrivateStaticAccess.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/classCheckPrivateStaticFieldDescriptor.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/classExtractFieldDescriptor.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/classNameTDZError.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/classPrivateFieldDestructureSet.js +7 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/classPrivateFieldGet.js +7 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/classPrivateFieldGet2.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/classPrivateFieldInitSpec.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/classPrivateFieldLooseBase.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/classPrivateFieldLooseKey.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/classPrivateFieldSet.js +7 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/classPrivateFieldSet2.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/classPrivateGetter.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/classPrivateMethodGet.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/classPrivateMethodInitSpec.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/classPrivateMethodSet.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/classPrivateSetter.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/classStaticPrivateFieldDestructureSet.js +7 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/classStaticPrivateFieldSpecGet.js +7 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/classStaticPrivateFieldSpecSet.js +7 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/classStaticPrivateMethodGet.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/classStaticPrivateMethodSet.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/construct.js +10 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/createClass.js +13 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/createForOfIteratorHelper.js +50 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/createForOfIteratorHelperLoose.js +19 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/createSuper.js +16 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/decorate.js +23 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/decorateMetadata.js +9 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/decorateParam.js +11 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/defaults.js +9 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/defineAccessor.js +8 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/defineEnumerableProperties.js +12 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/defineProperty.js +10 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/dispose.js +28 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/AwaitValue.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/OverloadYield.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/applyDecoratedDescriptor.js +9 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/applyDecs.js +236 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/applyDecs2203.js +184 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/applyDecs2203R.js +191 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/applyDecs2301.js +222 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/applyDecs2305.js +133 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/applyDecs2311.js +124 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/arrayLikeToArray.js +6 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/arrayWithHoles.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/arrayWithoutHoles.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/assertClassBrand.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/assertThisInitialized.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/asyncGeneratorDelegate.js +24 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/asyncIterator.js +45 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/asyncToGenerator.js +26 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/awaitAsyncGenerator.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/callSuper.js +7 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/checkInRHS.js +6 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/checkPrivateRedeclaration.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/classApplyDescriptorDestructureSet.js +10 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/classApplyDescriptorGet.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/classApplyDescriptorSet.js +7 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/classCallCheck.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/classCheckPrivateStaticAccess.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/classCheckPrivateStaticFieldDescriptor.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/classExtractFieldDescriptor.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/classNameTDZError.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/classPrivateFieldDestructureSet.js +7 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/classPrivateFieldGet.js +7 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/classPrivateFieldGet2.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/classPrivateFieldInitSpec.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/classPrivateFieldLooseBase.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/classPrivateFieldLooseKey.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/classPrivateFieldSet.js +7 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/classPrivateFieldSet2.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/classPrivateGetter.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/classPrivateMethodGet.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/classPrivateMethodInitSpec.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/classPrivateMethodSet.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/classPrivateSetter.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/classStaticPrivateFieldDestructureSet.js +7 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/classStaticPrivateFieldSpecGet.js +7 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/classStaticPrivateFieldSpecSet.js +7 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/classStaticPrivateMethodGet.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/classStaticPrivateMethodSet.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/construct.js +10 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/createClass.js +13 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/createForOfIteratorHelper.js +50 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/createForOfIteratorHelperLoose.js +19 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/createSuper.js +16 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/decorate.js +21 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/decorateMetadata.js +7 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/decorateParam.js +9 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/defaults.js +9 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/defineAccessor.js +8 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/defineEnumerableProperties.js +12 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/defineProperty.js +10 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/dispose.js +28 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/extends.js +10 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/get.js +11 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/getPrototypeOf.js +6 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/identity.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/importDeferProxy.js +27 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/inherits.js +14 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/inheritsLoose.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/initializerDefineProperty.js +9 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/initializerWarningHelper.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/instanceof.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/interopRequireDefault.js +6 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/interopRequireWildcard.js +27 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/isNativeFunction.js +8 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/isNativeReflectConstruct.js +9 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/iterableToArray.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/iterableToArrayLimit.js +28 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/jsx.js +22 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/maybeArrayLike.js +9 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/newArrowCheck.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/nonIterableRest.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/nonIterableSpread.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/nullishReceiverError.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/objectDestructuringEmpty.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/objectSpread.js +14 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/objectSpread2.js +23 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/objectWithoutProperties.js +13 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/objectWithoutPropertiesLoose.js +10 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/package.json +3 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/possibleConstructorReturn.js +8 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/readOnlyError.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/regeneratorRuntime.js +304 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/set.js +22 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/setFunctionName.js +12 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/setPrototypeOf.js +6 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/skipFirstGeneratorNext.js +7 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/slicedToArray.js +8 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/superPropBase.js +6 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/superPropGet.js +9 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/superPropSet.js +6 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/taggedTemplateLiteral.js +8 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/taggedTemplateLiteralLoose.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/tdz.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/temporalRef.js +6 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/temporalUndefined.js +2 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/toArray.js +8 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/toConsumableArray.js +8 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/toPrimitive.js +12 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/toPropertyKey.js +7 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/toSetter.js +10 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/typeof.js +10 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/unsupportedIterableToArray.js +9 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/using.js +12 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/usingCtx.js +59 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/wrapAsyncGenerator.js +69 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/wrapNativeSuper.js +27 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/wrapRegExp.js +51 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/esm/writeOnlyError.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/extends.js +10 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/get.js +11 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/getPrototypeOf.js +6 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/identity.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/importDeferProxy.js +27 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/inherits.js +14 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/inheritsLoose.js +5 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/initializerDefineProperty.js +9 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/initializerWarningHelper.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/instanceof.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/interopRequireDefault.js +6 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/interopRequireWildcard.js +27 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/isNativeFunction.js +8 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/isNativeReflectConstruct.js +9 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/iterableToArray.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/iterableToArrayLimit.js +28 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/jsx.js +22 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/maybeArrayLike.js +9 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/newArrowCheck.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/nonIterableRest.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/nonIterableSpread.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/nullishReceiverError.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/objectDestructuringEmpty.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/objectSpread.js +14 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/objectSpread2.js +23 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/objectWithoutProperties.js +13 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/objectWithoutPropertiesLoose.js +10 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/possibleConstructorReturn.js +8 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/readOnlyError.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/regeneratorRuntime.js +304 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/set.js +22 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/setFunctionName.js +12 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/setPrototypeOf.js +6 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/skipFirstGeneratorNext.js +7 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/slicedToArray.js +8 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/superPropBase.js +6 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/superPropGet.js +9 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/superPropSet.js +6 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/taggedTemplateLiteral.js +8 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/taggedTemplateLiteralLoose.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/tdz.js +4 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/temporalRef.js +6 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/temporalUndefined.js +2 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/toArray.js +8 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/toConsumableArray.js +8 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/toPrimitive.js +12 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/toPropertyKey.js +7 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/toSetter.js +10 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/typeof.js +10 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/unsupportedIterableToArray.js +9 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/using.js +12 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/usingCtx.js +59 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/wrapAsyncGenerator.js +69 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/wrapNativeSuper.js +27 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/wrapRegExp.js +51 -0
- package/runtime/node_modules/@oxc-project/runtime/src/helpers/writeOnlyError.js +4 -0
- package/runtime/node_modules/@oxc-project/types/LICENSE +22 -0
- package/runtime/node_modules/@oxc-project/types/README.md +3 -0
- package/runtime/node_modules/@oxc-project/types/package.json +26 -0
- package/runtime/node_modules/@oxc-project/types/types.d.ts +1912 -0
- package/runtime/node_modules/@oxc-transform/binding-win32-x64-msvc/README.md +3 -0
- package/runtime/node_modules/@oxc-transform/binding-win32-x64-msvc/package.json +41 -0
- package/runtime/node_modules/@oxc-transform/binding-win32-x64-msvc/transform.win32-x64-msvc.node +0 -0
- package/runtime/node_modules/@petamoriken/float16/LICENSE +21 -0
- package/runtime/node_modules/@petamoriken/float16/README.md +413 -0
- package/runtime/node_modules/@petamoriken/float16/browser/float16.js +1340 -0
- package/runtime/node_modules/@petamoriken/float16/browser/float16.mjs +1325 -0
- package/runtime/node_modules/@petamoriken/float16/index.d.ts +546 -0
- package/runtime/node_modules/@petamoriken/float16/index.v5.6.d.ts +546 -0
- package/runtime/node_modules/@petamoriken/float16/index.v5.7.d.ts +555 -0
- package/runtime/node_modules/@petamoriken/float16/inspect/node.cjs +25 -0
- package/runtime/node_modules/@petamoriken/float16/inspect/node.mjs +23 -0
- package/runtime/node_modules/@petamoriken/float16/lib/DataView.cjs +16 -0
- package/runtime/node_modules/@petamoriken/float16/lib/Float16Array.cjs +690 -0
- package/runtime/node_modules/@petamoriken/float16/lib/_util/arrayIterator.cjs +52 -0
- package/runtime/node_modules/@petamoriken/float16/lib/_util/brand.cjs +27 -0
- package/runtime/node_modules/@petamoriken/float16/lib/_util/converter.cjs +111 -0
- package/runtime/node_modules/@petamoriken/float16/lib/_util/is.cjs +78 -0
- package/runtime/node_modules/@petamoriken/float16/lib/_util/messages.cjs +18 -0
- package/runtime/node_modules/@petamoriken/float16/lib/_util/primordials.cjs +150 -0
- package/runtime/node_modules/@petamoriken/float16/lib/_util/spec.cjs +84 -0
- package/runtime/node_modules/@petamoriken/float16/lib/f16round.cjs +10 -0
- package/runtime/node_modules/@petamoriken/float16/lib/index.cjs +16 -0
- package/runtime/node_modules/@petamoriken/float16/lib/isTypedArray.cjs +11 -0
- package/runtime/node_modules/@petamoriken/float16/package.json +115 -0
- package/runtime/node_modules/@petamoriken/float16/src/DataView.mjs +35 -0
- package/runtime/node_modules/@petamoriken/float16/src/Float16Array.mjs +1194 -0
- package/runtime/node_modules/@petamoriken/float16/src/_util/arrayIterator.mjs +86 -0
- package/runtime/node_modules/@petamoriken/float16/src/_util/brand.mjs +31 -0
- package/runtime/node_modules/@petamoriken/float16/src/_util/converter.mjs +173 -0
- package/runtime/node_modules/@petamoriken/float16/src/_util/is.mjs +151 -0
- package/runtime/node_modules/@petamoriken/float16/src/_util/messages.mjs +22 -0
- package/runtime/node_modules/@petamoriken/float16/src/_util/primordials.mjs +254 -0
- package/runtime/node_modules/@petamoriken/float16/src/_util/spec.mjs +137 -0
- package/runtime/node_modules/@petamoriken/float16/src/f16round.mjs +10 -0
- package/runtime/node_modules/@petamoriken/float16/src/index.mjs +7 -0
- package/runtime/node_modules/@petamoriken/float16/src/isTypedArray.mjs +10 -0
- package/runtime/node_modules/get-tsconfig/LICENSE +21 -0
- package/runtime/node_modules/get-tsconfig/README.md +268 -0
- package/runtime/node_modules/get-tsconfig/dist/index.cjs +7 -0
- package/runtime/node_modules/get-tsconfig/dist/index.d.cts +2116 -0
- package/runtime/node_modules/get-tsconfig/dist/index.d.mts +2116 -0
- package/runtime/node_modules/get-tsconfig/dist/index.mjs +7 -0
- package/runtime/node_modules/get-tsconfig/package.json +46 -0
- package/runtime/node_modules/jsbi/LICENSE +176 -0
- package/runtime/node_modules/jsbi/README.md +173 -0
- package/runtime/node_modules/jsbi/dist/jsbi-cjs.js +2 -0
- package/runtime/node_modules/jsbi/dist/jsbi-cjs.js.map +1 -0
- package/runtime/node_modules/jsbi/dist/jsbi-umd.js +2 -0
- package/runtime/node_modules/jsbi/dist/jsbi-umd.js.map +1 -0
- package/runtime/node_modules/jsbi/dist/jsbi.mjs +2 -0
- package/runtime/node_modules/jsbi/dist/jsbi.mjs.map +1 -0
- package/runtime/node_modules/jsbi/jsbi.d.ts +43 -0
- package/runtime/node_modules/jsbi/package.json +35 -0
- package/runtime/node_modules/oxc-parser/LICENSE +22 -0
- package/runtime/node_modules/oxc-parser/README.md +167 -0
- package/runtime/node_modules/oxc-parser/package.json +153 -0
- package/runtime/node_modules/oxc-parser/src-js/bindings.js +601 -0
- package/runtime/node_modules/oxc-parser/src-js/generated/constants.js +105 -0
- package/runtime/node_modules/oxc-parser/src-js/generated/deserialize/js.js +5862 -0
- package/runtime/node_modules/oxc-parser/src-js/generated/deserialize/js_range.js +6403 -0
- package/runtime/node_modules/oxc-parser/src-js/generated/deserialize/ts.js +6154 -0
- package/runtime/node_modules/oxc-parser/src-js/generated/deserialize/ts_range.js +6723 -0
- package/runtime/node_modules/oxc-parser/src-js/generated/lazy/constructors.js +13875 -0
- package/runtime/node_modules/oxc-parser/src-js/generated/lazy/type_ids.js +191 -0
- package/runtime/node_modules/oxc-parser/src-js/generated/lazy/walk.js +5810 -0
- package/runtime/node_modules/oxc-parser/src-js/generated/visit/keys.js +220 -0
- package/runtime/node_modules/oxc-parser/src-js/generated/visit/type_ids.js +177 -0
- package/runtime/node_modules/oxc-parser/src-js/generated/visit/visitor.d.ts +387 -0
- package/runtime/node_modules/oxc-parser/src-js/generated/visit/walk.js +2455 -0
- package/runtime/node_modules/oxc-parser/src-js/index.d.ts +312 -0
- package/runtime/node_modules/oxc-parser/src-js/index.js +108 -0
- package/runtime/node_modules/oxc-parser/src-js/raw-transfer/common.js +301 -0
- package/runtime/node_modules/oxc-parser/src-js/raw-transfer/eager.js +255 -0
- package/runtime/node_modules/oxc-parser/src-js/raw-transfer/lazy-common.js +11 -0
- package/runtime/node_modules/oxc-parser/src-js/raw-transfer/lazy.js +162 -0
- package/runtime/node_modules/oxc-parser/src-js/raw-transfer/node-array.js +365 -0
- package/runtime/node_modules/oxc-parser/src-js/raw-transfer/supported.js +52 -0
- package/runtime/node_modules/oxc-parser/src-js/raw-transfer/visitor.js +127 -0
- package/runtime/node_modules/oxc-parser/src-js/visit/index.js +41 -0
- package/runtime/node_modules/oxc-parser/src-js/visit/visitor.js +405 -0
- package/runtime/node_modules/oxc-parser/src-js/wasm.js +13 -0
- package/runtime/node_modules/oxc-parser/src-js/webcontainer-fallback.cjs +21 -0
- package/runtime/node_modules/oxc-parser/src-js/wrap.js +57 -0
- package/runtime/node_modules/oxc-transform/LICENSE +22 -0
- package/runtime/node_modules/oxc-transform/README.md +84 -0
- package/runtime/node_modules/oxc-transform/browser.js +1 -0
- package/runtime/node_modules/oxc-transform/index.d.ts +658 -0
- package/runtime/node_modules/oxc-transform/index.js +598 -0
- package/runtime/node_modules/oxc-transform/package.json +114 -0
- package/runtime/node_modules/oxc-transform/webcontainer-fallback.cjs +21 -0
- package/runtime/node_modules/resolve-pkg-maps/LICENSE +21 -0
- package/runtime/node_modules/resolve-pkg-maps/README.md +216 -0
- package/runtime/node_modules/resolve-pkg-maps/dist/index.cjs +1 -0
- package/runtime/node_modules/resolve-pkg-maps/dist/index.d.cts +11 -0
- package/runtime/node_modules/resolve-pkg-maps/dist/index.d.mts +11 -0
- package/runtime/node_modules/resolve-pkg-maps/dist/index.mjs +1 -0
- package/runtime/node_modules/resolve-pkg-maps/package.json +42 -0
- package/runtime/node_modules/urlpattern-polyfill/LICENSE +19 -0
- package/runtime/node_modules/urlpattern-polyfill/README.md +242 -0
- package/runtime/node_modules/urlpattern-polyfill/dist/index.d.ts +9 -0
- package/runtime/node_modules/urlpattern-polyfill/dist/types.d.ts +49 -0
- package/runtime/node_modules/urlpattern-polyfill/dist/urlpattern.cjs +1 -0
- package/runtime/node_modules/urlpattern-polyfill/dist/urlpattern.js +1 -0
- package/runtime/node_modules/urlpattern-polyfill/index.cjs +7 -0
- package/runtime/node_modules/urlpattern-polyfill/index.js +7 -0
- package/runtime/node_modules/urlpattern-polyfill/package.json +149 -0
- package/runtime/version.mjs +1 -1
|
@@ -0,0 +1,690 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.isFloat16Array = isFloat16Array;
|
|
7
|
+
var _arrayIterator = require("./_util/arrayIterator.cjs");
|
|
8
|
+
var _brand = require("./_util/brand.cjs");
|
|
9
|
+
var _converter = require("./_util/converter.cjs");
|
|
10
|
+
var _is = require("./_util/is.cjs");
|
|
11
|
+
var _messages = require("./_util/messages.cjs");
|
|
12
|
+
var _primordials = require("./_util/primordials.cjs");
|
|
13
|
+
var _spec = require("./_util/spec.cjs");
|
|
14
|
+
const BYTES_PER_ELEMENT = 2;
|
|
15
|
+
const float16bitsArrays = new _primordials.NativeWeakMap();
|
|
16
|
+
function isFloat16Array(target) {
|
|
17
|
+
return (0, _primordials.WeakMapPrototypeHas)(float16bitsArrays, target) || !(0, _primordials.ArrayBufferIsView)(target) && (0, _brand.hasFloat16ArrayBrand)(target);
|
|
18
|
+
}
|
|
19
|
+
function assertFloat16Array(target) {
|
|
20
|
+
if (!isFloat16Array(target)) {
|
|
21
|
+
throw (0, _primordials.NativeTypeError)(_messages.THIS_IS_NOT_A_FLOAT16ARRAY_OBJECT);
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
function assertSpeciesTypedArray(target, count) {
|
|
25
|
+
const isTargetFloat16Array = isFloat16Array(target);
|
|
26
|
+
const isTargetTypedArray = (0, _is.isNativeTypedArray)(target);
|
|
27
|
+
if (!isTargetFloat16Array && !isTargetTypedArray) {
|
|
28
|
+
throw (0, _primordials.NativeTypeError)(_messages.SPECIES_CONSTRUCTOR_DIDNT_RETURN_TYPEDARRAY_OBJECT);
|
|
29
|
+
}
|
|
30
|
+
if (typeof count === "number") {
|
|
31
|
+
let length;
|
|
32
|
+
if (isTargetFloat16Array) {
|
|
33
|
+
const float16bitsArray = getFloat16BitsArray(target);
|
|
34
|
+
length = (0, _primordials.TypedArrayPrototypeGetLength)(float16bitsArray);
|
|
35
|
+
} else {
|
|
36
|
+
length = (0, _primordials.TypedArrayPrototypeGetLength)(target);
|
|
37
|
+
}
|
|
38
|
+
if (length < count) {
|
|
39
|
+
throw (0, _primordials.NativeTypeError)(_messages.DERIVED_CONSTRUCTOR_CREATED_TYPEDARRAY_OBJECT_WHICH_WAS_TOO_SMALL_LENGTH);
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
if ((0, _is.isNativeBigIntTypedArray)(target)) {
|
|
43
|
+
throw (0, _primordials.NativeTypeError)(_messages.CANNOT_MIX_BIGINT_AND_OTHER_TYPES);
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
function getFloat16BitsArray(float16) {
|
|
47
|
+
const float16bitsArray = (0, _primordials.WeakMapPrototypeGet)(float16bitsArrays, float16);
|
|
48
|
+
if (float16bitsArray !== undefined) {
|
|
49
|
+
const buffer = (0, _primordials.TypedArrayPrototypeGetBuffer)(float16bitsArray);
|
|
50
|
+
if ((0, _spec.IsDetachedBuffer)(buffer)) {
|
|
51
|
+
throw (0, _primordials.NativeTypeError)(_messages.ATTEMPTING_TO_ACCESS_DETACHED_ARRAYBUFFER);
|
|
52
|
+
}
|
|
53
|
+
return float16bitsArray;
|
|
54
|
+
}
|
|
55
|
+
const buffer = float16.buffer;
|
|
56
|
+
if ((0, _spec.IsDetachedBuffer)(buffer)) {
|
|
57
|
+
throw (0, _primordials.NativeTypeError)(_messages.ATTEMPTING_TO_ACCESS_DETACHED_ARRAYBUFFER);
|
|
58
|
+
}
|
|
59
|
+
const cloned = (0, _primordials.ReflectConstruct)(Float16Array, [buffer, float16.byteOffset, float16.length], float16.constructor);
|
|
60
|
+
return (0, _primordials.WeakMapPrototypeGet)(float16bitsArrays, cloned);
|
|
61
|
+
}
|
|
62
|
+
function copyToArray(float16bitsArray) {
|
|
63
|
+
const length = (0, _primordials.TypedArrayPrototypeGetLength)(float16bitsArray);
|
|
64
|
+
const array = [];
|
|
65
|
+
for (let i = 0; i < length; ++i) {
|
|
66
|
+
array[i] = (0, _converter.convertToNumber)(float16bitsArray[i]);
|
|
67
|
+
}
|
|
68
|
+
return array;
|
|
69
|
+
}
|
|
70
|
+
const TypedArrayPrototypeGetters = new _primordials.NativeWeakSet();
|
|
71
|
+
for (const key of (0, _primordials.ReflectOwnKeys)(_primordials.TypedArrayPrototype)) {
|
|
72
|
+
if (key === _primordials.SymbolToStringTag) {
|
|
73
|
+
continue;
|
|
74
|
+
}
|
|
75
|
+
const descriptor = (0, _primordials.ReflectGetOwnPropertyDescriptor)(_primordials.TypedArrayPrototype, key);
|
|
76
|
+
if ((0, _primordials.ObjectHasOwn)(descriptor, "get") && typeof descriptor.get === "function") {
|
|
77
|
+
(0, _primordials.WeakSetPrototypeAdd)(TypedArrayPrototypeGetters, descriptor.get);
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
const handler = (0, _primordials.ObjectFreeze)({
|
|
81
|
+
get(target, key, receiver) {
|
|
82
|
+
if ((0, _is.isCanonicalIntegerIndexString)(key) && (0, _primordials.ObjectHasOwn)(target, key)) {
|
|
83
|
+
return (0, _converter.convertToNumber)((0, _primordials.ReflectGet)(target, key));
|
|
84
|
+
}
|
|
85
|
+
if ((0, _primordials.WeakSetPrototypeHas)(TypedArrayPrototypeGetters, (0, _primordials.ObjectPrototype__lookupGetter__)(target, key))) {
|
|
86
|
+
return (0, _primordials.ReflectGet)(target, key);
|
|
87
|
+
}
|
|
88
|
+
return (0, _primordials.ReflectGet)(target, key, receiver);
|
|
89
|
+
},
|
|
90
|
+
set(target, key, value, receiver) {
|
|
91
|
+
if ((0, _is.isCanonicalIntegerIndexString)(key) && (0, _primordials.ObjectHasOwn)(target, key)) {
|
|
92
|
+
return (0, _primordials.ReflectSet)(target, key, (0, _converter.roundToFloat16Bits)(value));
|
|
93
|
+
}
|
|
94
|
+
return (0, _primordials.ReflectSet)(target, key, value, receiver);
|
|
95
|
+
},
|
|
96
|
+
getOwnPropertyDescriptor(target, key) {
|
|
97
|
+
if ((0, _is.isCanonicalIntegerIndexString)(key) && (0, _primordials.ObjectHasOwn)(target, key)) {
|
|
98
|
+
const descriptor = (0, _primordials.ReflectGetOwnPropertyDescriptor)(target, key);
|
|
99
|
+
descriptor.value = (0, _converter.convertToNumber)(descriptor.value);
|
|
100
|
+
return descriptor;
|
|
101
|
+
}
|
|
102
|
+
return (0, _primordials.ReflectGetOwnPropertyDescriptor)(target, key);
|
|
103
|
+
},
|
|
104
|
+
defineProperty(target, key, descriptor) {
|
|
105
|
+
if ((0, _is.isCanonicalIntegerIndexString)(key) && (0, _primordials.ObjectHasOwn)(target, key) && (0, _primordials.ObjectHasOwn)(descriptor, "value")) {
|
|
106
|
+
descriptor.value = (0, _converter.roundToFloat16Bits)(descriptor.value);
|
|
107
|
+
return (0, _primordials.ReflectDefineProperty)(target, key, descriptor);
|
|
108
|
+
}
|
|
109
|
+
return (0, _primordials.ReflectDefineProperty)(target, key, descriptor);
|
|
110
|
+
}
|
|
111
|
+
});
|
|
112
|
+
class Float16Array {
|
|
113
|
+
constructor(input, _byteOffset, _length) {
|
|
114
|
+
let float16bitsArray;
|
|
115
|
+
if (isFloat16Array(input)) {
|
|
116
|
+
float16bitsArray = (0, _primordials.ReflectConstruct)(_primordials.NativeUint16Array, [getFloat16BitsArray(input)], new.target);
|
|
117
|
+
} else if ((0, _is.isObject)(input) && !(0, _is.isAnyArrayBuffer)(input)) {
|
|
118
|
+
let list;
|
|
119
|
+
let length;
|
|
120
|
+
if ((0, _is.isNativeTypedArray)(input)) {
|
|
121
|
+
list = input;
|
|
122
|
+
length = (0, _primordials.TypedArrayPrototypeGetLength)(input);
|
|
123
|
+
const buffer = (0, _primordials.TypedArrayPrototypeGetBuffer)(input);
|
|
124
|
+
if ((0, _spec.IsDetachedBuffer)(buffer)) {
|
|
125
|
+
throw (0, _primordials.NativeTypeError)(_messages.ATTEMPTING_TO_ACCESS_DETACHED_ARRAYBUFFER);
|
|
126
|
+
}
|
|
127
|
+
if ((0, _is.isNativeBigIntTypedArray)(input)) {
|
|
128
|
+
throw (0, _primordials.NativeTypeError)(_messages.CANNOT_MIX_BIGINT_AND_OTHER_TYPES);
|
|
129
|
+
}
|
|
130
|
+
const data = new _primordials.NativeArrayBuffer(length * BYTES_PER_ELEMENT);
|
|
131
|
+
float16bitsArray = (0, _primordials.ReflectConstruct)(_primordials.NativeUint16Array, [data], new.target);
|
|
132
|
+
} else {
|
|
133
|
+
const iterator = input[_primordials.SymbolIterator];
|
|
134
|
+
if (iterator != null && typeof iterator !== "function") {
|
|
135
|
+
throw (0, _primordials.NativeTypeError)(_messages.ITERATOR_PROPERTY_IS_NOT_CALLABLE);
|
|
136
|
+
}
|
|
137
|
+
if (iterator != null) {
|
|
138
|
+
if ((0, _is.isOrdinaryArray)(input)) {
|
|
139
|
+
list = input;
|
|
140
|
+
length = input.length;
|
|
141
|
+
} else {
|
|
142
|
+
list = [...(input)];
|
|
143
|
+
length = list.length;
|
|
144
|
+
}
|
|
145
|
+
} else {
|
|
146
|
+
list = input;
|
|
147
|
+
length = (0, _spec.ToLength)(list.length);
|
|
148
|
+
}
|
|
149
|
+
float16bitsArray = (0, _primordials.ReflectConstruct)(_primordials.NativeUint16Array, [length], new.target);
|
|
150
|
+
}
|
|
151
|
+
for (let i = 0; i < length; ++i) {
|
|
152
|
+
float16bitsArray[i] = (0, _converter.roundToFloat16Bits)(list[i]);
|
|
153
|
+
}
|
|
154
|
+
} else {
|
|
155
|
+
float16bitsArray = (0, _primordials.ReflectConstruct)(_primordials.NativeUint16Array, arguments, new.target);
|
|
156
|
+
}
|
|
157
|
+
const proxy = new _primordials.NativeProxy(float16bitsArray, handler);
|
|
158
|
+
(0, _primordials.WeakMapPrototypeSet)(float16bitsArrays, proxy, float16bitsArray);
|
|
159
|
+
return proxy;
|
|
160
|
+
}
|
|
161
|
+
static from(src, ...opts) {
|
|
162
|
+
const Constructor = this;
|
|
163
|
+
if (!(0, _primordials.ReflectHas)(Constructor, _brand.brand)) {
|
|
164
|
+
throw (0, _primordials.NativeTypeError)(_messages.THIS_CONSTRUCTOR_IS_NOT_A_SUBCLASS_OF_FLOAT16ARRAY);
|
|
165
|
+
}
|
|
166
|
+
if (Constructor === Float16Array) {
|
|
167
|
+
if (isFloat16Array(src) && opts.length === 0) {
|
|
168
|
+
const float16bitsArray = getFloat16BitsArray(src);
|
|
169
|
+
const uint16 = new _primordials.NativeUint16Array((0, _primordials.TypedArrayPrototypeGetBuffer)(float16bitsArray), (0, _primordials.TypedArrayPrototypeGetByteOffset)(float16bitsArray), (0, _primordials.TypedArrayPrototypeGetLength)(float16bitsArray));
|
|
170
|
+
return new Float16Array((0, _primordials.TypedArrayPrototypeGetBuffer)((0, _primordials.TypedArrayPrototypeSlice)(uint16)));
|
|
171
|
+
}
|
|
172
|
+
if (opts.length === 0) {
|
|
173
|
+
return new Float16Array((0, _primordials.TypedArrayPrototypeGetBuffer)((0, _primordials.Uint16ArrayFrom)(src, _converter.roundToFloat16Bits)));
|
|
174
|
+
}
|
|
175
|
+
const mapFunc = opts[0];
|
|
176
|
+
const thisArg = opts[1];
|
|
177
|
+
return new Float16Array((0, _primordials.TypedArrayPrototypeGetBuffer)((0, _primordials.Uint16ArrayFrom)(src, function (val, ...args) {
|
|
178
|
+
return (0, _converter.roundToFloat16Bits)((0, _primordials.ReflectApply)(mapFunc, this, [val, ...(0, _arrayIterator.safeIfNeeded)(args)]));
|
|
179
|
+
}, thisArg)));
|
|
180
|
+
}
|
|
181
|
+
let list;
|
|
182
|
+
let length;
|
|
183
|
+
const iterator = src[_primordials.SymbolIterator];
|
|
184
|
+
if (iterator != null && typeof iterator !== "function") {
|
|
185
|
+
throw (0, _primordials.NativeTypeError)(_messages.ITERATOR_PROPERTY_IS_NOT_CALLABLE);
|
|
186
|
+
}
|
|
187
|
+
if (iterator != null) {
|
|
188
|
+
if ((0, _is.isOrdinaryArray)(src)) {
|
|
189
|
+
list = src;
|
|
190
|
+
length = src.length;
|
|
191
|
+
} else if ((0, _is.isOrdinaryNativeTypedArray)(src)) {
|
|
192
|
+
list = src;
|
|
193
|
+
length = (0, _primordials.TypedArrayPrototypeGetLength)(src);
|
|
194
|
+
} else {
|
|
195
|
+
list = [...src];
|
|
196
|
+
length = list.length;
|
|
197
|
+
}
|
|
198
|
+
} else {
|
|
199
|
+
if (src == null) {
|
|
200
|
+
throw (0, _primordials.NativeTypeError)(_messages.CANNOT_CONVERT_UNDEFINED_OR_NULL_TO_OBJECT);
|
|
201
|
+
}
|
|
202
|
+
list = (0, _primordials.NativeObject)(src);
|
|
203
|
+
length = (0, _spec.ToLength)(list.length);
|
|
204
|
+
}
|
|
205
|
+
const array = new Constructor(length);
|
|
206
|
+
if (opts.length === 0) {
|
|
207
|
+
for (let i = 0; i < length; ++i) {
|
|
208
|
+
array[i] = list[i];
|
|
209
|
+
}
|
|
210
|
+
} else {
|
|
211
|
+
const mapFunc = opts[0];
|
|
212
|
+
const thisArg = opts[1];
|
|
213
|
+
for (let i = 0; i < length; ++i) {
|
|
214
|
+
array[i] = (0, _primordials.ReflectApply)(mapFunc, thisArg, [list[i], i]);
|
|
215
|
+
}
|
|
216
|
+
}
|
|
217
|
+
return array;
|
|
218
|
+
}
|
|
219
|
+
static of(...items) {
|
|
220
|
+
const Constructor = this;
|
|
221
|
+
if (!(0, _primordials.ReflectHas)(Constructor, _brand.brand)) {
|
|
222
|
+
throw (0, _primordials.NativeTypeError)(_messages.THIS_CONSTRUCTOR_IS_NOT_A_SUBCLASS_OF_FLOAT16ARRAY);
|
|
223
|
+
}
|
|
224
|
+
const length = items.length;
|
|
225
|
+
if (Constructor === Float16Array) {
|
|
226
|
+
const proxy = new Float16Array(length);
|
|
227
|
+
const float16bitsArray = getFloat16BitsArray(proxy);
|
|
228
|
+
for (let i = 0; i < length; ++i) {
|
|
229
|
+
float16bitsArray[i] = (0, _converter.roundToFloat16Bits)(items[i]);
|
|
230
|
+
}
|
|
231
|
+
return proxy;
|
|
232
|
+
}
|
|
233
|
+
const array = new Constructor(length);
|
|
234
|
+
for (let i = 0; i < length; ++i) {
|
|
235
|
+
array[i] = items[i];
|
|
236
|
+
}
|
|
237
|
+
return array;
|
|
238
|
+
}
|
|
239
|
+
keys() {
|
|
240
|
+
assertFloat16Array(this);
|
|
241
|
+
const float16bitsArray = getFloat16BitsArray(this);
|
|
242
|
+
return (0, _primordials.TypedArrayPrototypeKeys)(float16bitsArray);
|
|
243
|
+
}
|
|
244
|
+
values() {
|
|
245
|
+
assertFloat16Array(this);
|
|
246
|
+
const float16bitsArray = getFloat16BitsArray(this);
|
|
247
|
+
return (0, _arrayIterator.wrap)(function* () {
|
|
248
|
+
for (const val of (0, _primordials.TypedArrayPrototypeValues)(float16bitsArray)) {
|
|
249
|
+
yield (0, _converter.convertToNumber)(val);
|
|
250
|
+
}
|
|
251
|
+
}());
|
|
252
|
+
}
|
|
253
|
+
entries() {
|
|
254
|
+
assertFloat16Array(this);
|
|
255
|
+
const float16bitsArray = getFloat16BitsArray(this);
|
|
256
|
+
return (0, _arrayIterator.wrap)(function* () {
|
|
257
|
+
for (const [i, val] of (0, _primordials.TypedArrayPrototypeEntries)(float16bitsArray)) {
|
|
258
|
+
yield ([i, (0, _converter.convertToNumber)(val)]);
|
|
259
|
+
}
|
|
260
|
+
}());
|
|
261
|
+
}
|
|
262
|
+
at(index) {
|
|
263
|
+
assertFloat16Array(this);
|
|
264
|
+
const float16bitsArray = getFloat16BitsArray(this);
|
|
265
|
+
const length = (0, _primordials.TypedArrayPrototypeGetLength)(float16bitsArray);
|
|
266
|
+
const relativeIndex = (0, _spec.ToIntegerOrInfinity)(index);
|
|
267
|
+
const k = relativeIndex >= 0 ? relativeIndex : length + relativeIndex;
|
|
268
|
+
if (k < 0 || k >= length) {
|
|
269
|
+
return;
|
|
270
|
+
}
|
|
271
|
+
return (0, _converter.convertToNumber)(float16bitsArray[k]);
|
|
272
|
+
}
|
|
273
|
+
with(index, value) {
|
|
274
|
+
assertFloat16Array(this);
|
|
275
|
+
const float16bitsArray = getFloat16BitsArray(this);
|
|
276
|
+
const length = (0, _primordials.TypedArrayPrototypeGetLength)(float16bitsArray);
|
|
277
|
+
const relativeIndex = (0, _spec.ToIntegerOrInfinity)(index);
|
|
278
|
+
const k = relativeIndex >= 0 ? relativeIndex : length + relativeIndex;
|
|
279
|
+
const number = +value;
|
|
280
|
+
if (k < 0 || k >= length) {
|
|
281
|
+
throw (0, _primordials.NativeRangeError)(_messages.OFFSET_IS_OUT_OF_BOUNDS);
|
|
282
|
+
}
|
|
283
|
+
const uint16 = new _primordials.NativeUint16Array((0, _primordials.TypedArrayPrototypeGetBuffer)(float16bitsArray), (0, _primordials.TypedArrayPrototypeGetByteOffset)(float16bitsArray), (0, _primordials.TypedArrayPrototypeGetLength)(float16bitsArray));
|
|
284
|
+
const cloned = new Float16Array((0, _primordials.TypedArrayPrototypeGetBuffer)((0, _primordials.TypedArrayPrototypeSlice)(uint16)));
|
|
285
|
+
const array = getFloat16BitsArray(cloned);
|
|
286
|
+
array[k] = (0, _converter.roundToFloat16Bits)(number);
|
|
287
|
+
return cloned;
|
|
288
|
+
}
|
|
289
|
+
map(callback, ...opts) {
|
|
290
|
+
assertFloat16Array(this);
|
|
291
|
+
const float16bitsArray = getFloat16BitsArray(this);
|
|
292
|
+
const length = (0, _primordials.TypedArrayPrototypeGetLength)(float16bitsArray);
|
|
293
|
+
const thisArg = opts[0];
|
|
294
|
+
const Constructor = (0, _spec.SpeciesConstructor)(float16bitsArray, Float16Array);
|
|
295
|
+
if (Constructor === Float16Array) {
|
|
296
|
+
const proxy = new Float16Array(length);
|
|
297
|
+
const array = getFloat16BitsArray(proxy);
|
|
298
|
+
for (let i = 0; i < length; ++i) {
|
|
299
|
+
const val = (0, _converter.convertToNumber)(float16bitsArray[i]);
|
|
300
|
+
array[i] = (0, _converter.roundToFloat16Bits)((0, _primordials.ReflectApply)(callback, thisArg, [val, i, this]));
|
|
301
|
+
}
|
|
302
|
+
return proxy;
|
|
303
|
+
}
|
|
304
|
+
const array = new Constructor(length);
|
|
305
|
+
assertSpeciesTypedArray(array, length);
|
|
306
|
+
for (let i = 0; i < length; ++i) {
|
|
307
|
+
const val = (0, _converter.convertToNumber)(float16bitsArray[i]);
|
|
308
|
+
array[i] = (0, _primordials.ReflectApply)(callback, thisArg, [val, i, this]);
|
|
309
|
+
}
|
|
310
|
+
return array;
|
|
311
|
+
}
|
|
312
|
+
filter(callback, ...opts) {
|
|
313
|
+
assertFloat16Array(this);
|
|
314
|
+
const float16bitsArray = getFloat16BitsArray(this);
|
|
315
|
+
const length = (0, _primordials.TypedArrayPrototypeGetLength)(float16bitsArray);
|
|
316
|
+
const thisArg = opts[0];
|
|
317
|
+
const kept = [];
|
|
318
|
+
for (let i = 0; i < length; ++i) {
|
|
319
|
+
const val = (0, _converter.convertToNumber)(float16bitsArray[i]);
|
|
320
|
+
if ((0, _primordials.ReflectApply)(callback, thisArg, [val, i, this])) {
|
|
321
|
+
(0, _primordials.ArrayPrototypePush)(kept, val);
|
|
322
|
+
}
|
|
323
|
+
}
|
|
324
|
+
const Constructor = (0, _spec.SpeciesConstructor)(float16bitsArray, Float16Array);
|
|
325
|
+
const array = new Constructor(kept);
|
|
326
|
+
assertSpeciesTypedArray(array);
|
|
327
|
+
return array;
|
|
328
|
+
}
|
|
329
|
+
reduce(callback, ...opts) {
|
|
330
|
+
assertFloat16Array(this);
|
|
331
|
+
const float16bitsArray = getFloat16BitsArray(this);
|
|
332
|
+
const length = (0, _primordials.TypedArrayPrototypeGetLength)(float16bitsArray);
|
|
333
|
+
if (length === 0 && opts.length === 0) {
|
|
334
|
+
throw (0, _primordials.NativeTypeError)(_messages.REDUCE_OF_EMPTY_ARRAY_WITH_NO_INITIAL_VALUE);
|
|
335
|
+
}
|
|
336
|
+
let accumulator, start;
|
|
337
|
+
if (opts.length === 0) {
|
|
338
|
+
accumulator = (0, _converter.convertToNumber)(float16bitsArray[0]);
|
|
339
|
+
start = 1;
|
|
340
|
+
} else {
|
|
341
|
+
accumulator = opts[0];
|
|
342
|
+
start = 0;
|
|
343
|
+
}
|
|
344
|
+
for (let i = start; i < length; ++i) {
|
|
345
|
+
accumulator = callback(accumulator, (0, _converter.convertToNumber)(float16bitsArray[i]), i, this);
|
|
346
|
+
}
|
|
347
|
+
return accumulator;
|
|
348
|
+
}
|
|
349
|
+
reduceRight(callback, ...opts) {
|
|
350
|
+
assertFloat16Array(this);
|
|
351
|
+
const float16bitsArray = getFloat16BitsArray(this);
|
|
352
|
+
const length = (0, _primordials.TypedArrayPrototypeGetLength)(float16bitsArray);
|
|
353
|
+
if (length === 0 && opts.length === 0) {
|
|
354
|
+
throw (0, _primordials.NativeTypeError)(_messages.REDUCE_OF_EMPTY_ARRAY_WITH_NO_INITIAL_VALUE);
|
|
355
|
+
}
|
|
356
|
+
let accumulator, start;
|
|
357
|
+
if (opts.length === 0) {
|
|
358
|
+
accumulator = (0, _converter.convertToNumber)(float16bitsArray[length - 1]);
|
|
359
|
+
start = length - 2;
|
|
360
|
+
} else {
|
|
361
|
+
accumulator = opts[0];
|
|
362
|
+
start = length - 1;
|
|
363
|
+
}
|
|
364
|
+
for (let i = start; i >= 0; --i) {
|
|
365
|
+
accumulator = callback(accumulator, (0, _converter.convertToNumber)(float16bitsArray[i]), i, this);
|
|
366
|
+
}
|
|
367
|
+
return accumulator;
|
|
368
|
+
}
|
|
369
|
+
forEach(callback, ...opts) {
|
|
370
|
+
assertFloat16Array(this);
|
|
371
|
+
const float16bitsArray = getFloat16BitsArray(this);
|
|
372
|
+
const length = (0, _primordials.TypedArrayPrototypeGetLength)(float16bitsArray);
|
|
373
|
+
const thisArg = opts[0];
|
|
374
|
+
for (let i = 0; i < length; ++i) {
|
|
375
|
+
(0, _primordials.ReflectApply)(callback, thisArg, [(0, _converter.convertToNumber)(float16bitsArray[i]), i, this]);
|
|
376
|
+
}
|
|
377
|
+
}
|
|
378
|
+
find(callback, ...opts) {
|
|
379
|
+
assertFloat16Array(this);
|
|
380
|
+
const float16bitsArray = getFloat16BitsArray(this);
|
|
381
|
+
const length = (0, _primordials.TypedArrayPrototypeGetLength)(float16bitsArray);
|
|
382
|
+
const thisArg = opts[0];
|
|
383
|
+
for (let i = 0; i < length; ++i) {
|
|
384
|
+
const value = (0, _converter.convertToNumber)(float16bitsArray[i]);
|
|
385
|
+
if ((0, _primordials.ReflectApply)(callback, thisArg, [value, i, this])) {
|
|
386
|
+
return value;
|
|
387
|
+
}
|
|
388
|
+
}
|
|
389
|
+
}
|
|
390
|
+
findIndex(callback, ...opts) {
|
|
391
|
+
assertFloat16Array(this);
|
|
392
|
+
const float16bitsArray = getFloat16BitsArray(this);
|
|
393
|
+
const length = (0, _primordials.TypedArrayPrototypeGetLength)(float16bitsArray);
|
|
394
|
+
const thisArg = opts[0];
|
|
395
|
+
for (let i = 0; i < length; ++i) {
|
|
396
|
+
const value = (0, _converter.convertToNumber)(float16bitsArray[i]);
|
|
397
|
+
if ((0, _primordials.ReflectApply)(callback, thisArg, [value, i, this])) {
|
|
398
|
+
return i;
|
|
399
|
+
}
|
|
400
|
+
}
|
|
401
|
+
return -1;
|
|
402
|
+
}
|
|
403
|
+
findLast(callback, ...opts) {
|
|
404
|
+
assertFloat16Array(this);
|
|
405
|
+
const float16bitsArray = getFloat16BitsArray(this);
|
|
406
|
+
const length = (0, _primordials.TypedArrayPrototypeGetLength)(float16bitsArray);
|
|
407
|
+
const thisArg = opts[0];
|
|
408
|
+
for (let i = length - 1; i >= 0; --i) {
|
|
409
|
+
const value = (0, _converter.convertToNumber)(float16bitsArray[i]);
|
|
410
|
+
if ((0, _primordials.ReflectApply)(callback, thisArg, [value, i, this])) {
|
|
411
|
+
return value;
|
|
412
|
+
}
|
|
413
|
+
}
|
|
414
|
+
}
|
|
415
|
+
findLastIndex(callback, ...opts) {
|
|
416
|
+
assertFloat16Array(this);
|
|
417
|
+
const float16bitsArray = getFloat16BitsArray(this);
|
|
418
|
+
const length = (0, _primordials.TypedArrayPrototypeGetLength)(float16bitsArray);
|
|
419
|
+
const thisArg = opts[0];
|
|
420
|
+
for (let i = length - 1; i >= 0; --i) {
|
|
421
|
+
const value = (0, _converter.convertToNumber)(float16bitsArray[i]);
|
|
422
|
+
if ((0, _primordials.ReflectApply)(callback, thisArg, [value, i, this])) {
|
|
423
|
+
return i;
|
|
424
|
+
}
|
|
425
|
+
}
|
|
426
|
+
return -1;
|
|
427
|
+
}
|
|
428
|
+
every(callback, ...opts) {
|
|
429
|
+
assertFloat16Array(this);
|
|
430
|
+
const float16bitsArray = getFloat16BitsArray(this);
|
|
431
|
+
const length = (0, _primordials.TypedArrayPrototypeGetLength)(float16bitsArray);
|
|
432
|
+
const thisArg = opts[0];
|
|
433
|
+
for (let i = 0; i < length; ++i) {
|
|
434
|
+
if (!(0, _primordials.ReflectApply)(callback, thisArg, [(0, _converter.convertToNumber)(float16bitsArray[i]), i, this])) {
|
|
435
|
+
return false;
|
|
436
|
+
}
|
|
437
|
+
}
|
|
438
|
+
return true;
|
|
439
|
+
}
|
|
440
|
+
some(callback, ...opts) {
|
|
441
|
+
assertFloat16Array(this);
|
|
442
|
+
const float16bitsArray = getFloat16BitsArray(this);
|
|
443
|
+
const length = (0, _primordials.TypedArrayPrototypeGetLength)(float16bitsArray);
|
|
444
|
+
const thisArg = opts[0];
|
|
445
|
+
for (let i = 0; i < length; ++i) {
|
|
446
|
+
if ((0, _primordials.ReflectApply)(callback, thisArg, [(0, _converter.convertToNumber)(float16bitsArray[i]), i, this])) {
|
|
447
|
+
return true;
|
|
448
|
+
}
|
|
449
|
+
}
|
|
450
|
+
return false;
|
|
451
|
+
}
|
|
452
|
+
set(input, ...opts) {
|
|
453
|
+
assertFloat16Array(this);
|
|
454
|
+
const float16bitsArray = getFloat16BitsArray(this);
|
|
455
|
+
const targetOffset = (0, _spec.ToIntegerOrInfinity)(opts[0]);
|
|
456
|
+
if (targetOffset < 0) {
|
|
457
|
+
throw (0, _primordials.NativeRangeError)(_messages.OFFSET_IS_OUT_OF_BOUNDS);
|
|
458
|
+
}
|
|
459
|
+
if (input == null) {
|
|
460
|
+
throw (0, _primordials.NativeTypeError)(_messages.CANNOT_CONVERT_UNDEFINED_OR_NULL_TO_OBJECT);
|
|
461
|
+
}
|
|
462
|
+
if ((0, _is.isNativeBigIntTypedArray)(input)) {
|
|
463
|
+
throw (0, _primordials.NativeTypeError)(_messages.CANNOT_MIX_BIGINT_AND_OTHER_TYPES);
|
|
464
|
+
}
|
|
465
|
+
if (isFloat16Array(input)) {
|
|
466
|
+
return (0, _primordials.TypedArrayPrototypeSet)(getFloat16BitsArray(this), getFloat16BitsArray(input), targetOffset);
|
|
467
|
+
}
|
|
468
|
+
if ((0, _is.isNativeTypedArray)(input)) {
|
|
469
|
+
const buffer = (0, _primordials.TypedArrayPrototypeGetBuffer)(input);
|
|
470
|
+
if ((0, _spec.IsDetachedBuffer)(buffer)) {
|
|
471
|
+
throw (0, _primordials.NativeTypeError)(_messages.ATTEMPTING_TO_ACCESS_DETACHED_ARRAYBUFFER);
|
|
472
|
+
}
|
|
473
|
+
}
|
|
474
|
+
const targetLength = (0, _primordials.TypedArrayPrototypeGetLength)(float16bitsArray);
|
|
475
|
+
const src = (0, _primordials.NativeObject)(input);
|
|
476
|
+
const srcLength = (0, _spec.ToLength)(src.length);
|
|
477
|
+
if (targetOffset === Infinity || srcLength + targetOffset > targetLength) {
|
|
478
|
+
throw (0, _primordials.NativeRangeError)(_messages.OFFSET_IS_OUT_OF_BOUNDS);
|
|
479
|
+
}
|
|
480
|
+
for (let i = 0; i < srcLength; ++i) {
|
|
481
|
+
float16bitsArray[i + targetOffset] = (0, _converter.roundToFloat16Bits)(src[i]);
|
|
482
|
+
}
|
|
483
|
+
}
|
|
484
|
+
reverse() {
|
|
485
|
+
assertFloat16Array(this);
|
|
486
|
+
const float16bitsArray = getFloat16BitsArray(this);
|
|
487
|
+
(0, _primordials.TypedArrayPrototypeReverse)(float16bitsArray);
|
|
488
|
+
return this;
|
|
489
|
+
}
|
|
490
|
+
toReversed() {
|
|
491
|
+
assertFloat16Array(this);
|
|
492
|
+
const float16bitsArray = getFloat16BitsArray(this);
|
|
493
|
+
const uint16 = new _primordials.NativeUint16Array((0, _primordials.TypedArrayPrototypeGetBuffer)(float16bitsArray), (0, _primordials.TypedArrayPrototypeGetByteOffset)(float16bitsArray), (0, _primordials.TypedArrayPrototypeGetLength)(float16bitsArray));
|
|
494
|
+
const cloned = new Float16Array((0, _primordials.TypedArrayPrototypeGetBuffer)((0, _primordials.TypedArrayPrototypeSlice)(uint16)));
|
|
495
|
+
const clonedFloat16bitsArray = getFloat16BitsArray(cloned);
|
|
496
|
+
(0, _primordials.TypedArrayPrototypeReverse)(clonedFloat16bitsArray);
|
|
497
|
+
return cloned;
|
|
498
|
+
}
|
|
499
|
+
fill(value, ...opts) {
|
|
500
|
+
assertFloat16Array(this);
|
|
501
|
+
const float16bitsArray = getFloat16BitsArray(this);
|
|
502
|
+
(0, _primordials.TypedArrayPrototypeFill)(float16bitsArray, (0, _converter.roundToFloat16Bits)(value), ...(0, _arrayIterator.safeIfNeeded)(opts));
|
|
503
|
+
return this;
|
|
504
|
+
}
|
|
505
|
+
copyWithin(target, start, ...opts) {
|
|
506
|
+
assertFloat16Array(this);
|
|
507
|
+
const float16bitsArray = getFloat16BitsArray(this);
|
|
508
|
+
(0, _primordials.TypedArrayPrototypeCopyWithin)(float16bitsArray, target, start, ...(0, _arrayIterator.safeIfNeeded)(opts));
|
|
509
|
+
return this;
|
|
510
|
+
}
|
|
511
|
+
sort(compareFn) {
|
|
512
|
+
assertFloat16Array(this);
|
|
513
|
+
const float16bitsArray = getFloat16BitsArray(this);
|
|
514
|
+
const sortCompare = compareFn !== undefined ? compareFn : _spec.defaultCompare;
|
|
515
|
+
(0, _primordials.TypedArrayPrototypeSort)(float16bitsArray, (x, y) => {
|
|
516
|
+
return sortCompare((0, _converter.convertToNumber)(x), (0, _converter.convertToNumber)(y));
|
|
517
|
+
});
|
|
518
|
+
return this;
|
|
519
|
+
}
|
|
520
|
+
toSorted(compareFn) {
|
|
521
|
+
assertFloat16Array(this);
|
|
522
|
+
const float16bitsArray = getFloat16BitsArray(this);
|
|
523
|
+
if (compareFn !== undefined && typeof compareFn !== "function") {
|
|
524
|
+
throw new _primordials.NativeTypeError(_messages.THE_COMPARISON_FUNCTION_MUST_BE_EITHER_A_FUNCTION_OR_UNDEFINED);
|
|
525
|
+
}
|
|
526
|
+
const sortCompare = compareFn !== undefined ? compareFn : _spec.defaultCompare;
|
|
527
|
+
const uint16 = new _primordials.NativeUint16Array((0, _primordials.TypedArrayPrototypeGetBuffer)(float16bitsArray), (0, _primordials.TypedArrayPrototypeGetByteOffset)(float16bitsArray), (0, _primordials.TypedArrayPrototypeGetLength)(float16bitsArray));
|
|
528
|
+
const cloned = new Float16Array((0, _primordials.TypedArrayPrototypeGetBuffer)((0, _primordials.TypedArrayPrototypeSlice)(uint16)));
|
|
529
|
+
const clonedFloat16bitsArray = getFloat16BitsArray(cloned);
|
|
530
|
+
(0, _primordials.TypedArrayPrototypeSort)(clonedFloat16bitsArray, (x, y) => {
|
|
531
|
+
return sortCompare((0, _converter.convertToNumber)(x), (0, _converter.convertToNumber)(y));
|
|
532
|
+
});
|
|
533
|
+
return cloned;
|
|
534
|
+
}
|
|
535
|
+
slice(start, end) {
|
|
536
|
+
assertFloat16Array(this);
|
|
537
|
+
const float16bitsArray = getFloat16BitsArray(this);
|
|
538
|
+
const Constructor = (0, _spec.SpeciesConstructor)(float16bitsArray, Float16Array);
|
|
539
|
+
if (Constructor === Float16Array) {
|
|
540
|
+
const uint16 = new _primordials.NativeUint16Array((0, _primordials.TypedArrayPrototypeGetBuffer)(float16bitsArray), (0, _primordials.TypedArrayPrototypeGetByteOffset)(float16bitsArray), (0, _primordials.TypedArrayPrototypeGetLength)(float16bitsArray));
|
|
541
|
+
return new Float16Array((0, _primordials.TypedArrayPrototypeGetBuffer)((0, _primordials.TypedArrayPrototypeSlice)(uint16, start, end)));
|
|
542
|
+
}
|
|
543
|
+
const length = (0, _primordials.TypedArrayPrototypeGetLength)(float16bitsArray);
|
|
544
|
+
const relativeStart = (0, _spec.ToIntegerOrInfinity)(start);
|
|
545
|
+
const relativeEnd = end === undefined ? length : (0, _spec.ToIntegerOrInfinity)(end);
|
|
546
|
+
let k;
|
|
547
|
+
if (relativeStart === -Infinity) {
|
|
548
|
+
k = 0;
|
|
549
|
+
} else if (relativeStart < 0) {
|
|
550
|
+
k = length + relativeStart > 0 ? length + relativeStart : 0;
|
|
551
|
+
} else {
|
|
552
|
+
k = length < relativeStart ? length : relativeStart;
|
|
553
|
+
}
|
|
554
|
+
let final;
|
|
555
|
+
if (relativeEnd === -Infinity) {
|
|
556
|
+
final = 0;
|
|
557
|
+
} else if (relativeEnd < 0) {
|
|
558
|
+
final = length + relativeEnd > 0 ? length + relativeEnd : 0;
|
|
559
|
+
} else {
|
|
560
|
+
final = length < relativeEnd ? length : relativeEnd;
|
|
561
|
+
}
|
|
562
|
+
const count = final - k > 0 ? final - k : 0;
|
|
563
|
+
const array = new Constructor(count);
|
|
564
|
+
assertSpeciesTypedArray(array, count);
|
|
565
|
+
if (count === 0) {
|
|
566
|
+
return array;
|
|
567
|
+
}
|
|
568
|
+
const buffer = (0, _primordials.TypedArrayPrototypeGetBuffer)(float16bitsArray);
|
|
569
|
+
if ((0, _spec.IsDetachedBuffer)(buffer)) {
|
|
570
|
+
throw (0, _primordials.NativeTypeError)(_messages.ATTEMPTING_TO_ACCESS_DETACHED_ARRAYBUFFER);
|
|
571
|
+
}
|
|
572
|
+
let n = 0;
|
|
573
|
+
while (k < final) {
|
|
574
|
+
array[n] = (0, _converter.convertToNumber)(float16bitsArray[k]);
|
|
575
|
+
++k;
|
|
576
|
+
++n;
|
|
577
|
+
}
|
|
578
|
+
return array;
|
|
579
|
+
}
|
|
580
|
+
subarray(begin, end) {
|
|
581
|
+
assertFloat16Array(this);
|
|
582
|
+
const float16bitsArray = getFloat16BitsArray(this);
|
|
583
|
+
const Constructor = (0, _spec.SpeciesConstructor)(float16bitsArray, Float16Array);
|
|
584
|
+
const uint16 = new _primordials.NativeUint16Array((0, _primordials.TypedArrayPrototypeGetBuffer)(float16bitsArray), (0, _primordials.TypedArrayPrototypeGetByteOffset)(float16bitsArray), (0, _primordials.TypedArrayPrototypeGetLength)(float16bitsArray));
|
|
585
|
+
const uint16Subarray = (0, _primordials.TypedArrayPrototypeSubarray)(uint16, begin, end);
|
|
586
|
+
const array = new Constructor((0, _primordials.TypedArrayPrototypeGetBuffer)(uint16Subarray), (0, _primordials.TypedArrayPrototypeGetByteOffset)(uint16Subarray), (0, _primordials.TypedArrayPrototypeGetLength)(uint16Subarray));
|
|
587
|
+
assertSpeciesTypedArray(array);
|
|
588
|
+
return array;
|
|
589
|
+
}
|
|
590
|
+
indexOf(element, ...opts) {
|
|
591
|
+
assertFloat16Array(this);
|
|
592
|
+
const float16bitsArray = getFloat16BitsArray(this);
|
|
593
|
+
const length = (0, _primordials.TypedArrayPrototypeGetLength)(float16bitsArray);
|
|
594
|
+
let from = (0, _spec.ToIntegerOrInfinity)(opts[0]);
|
|
595
|
+
if (from === Infinity) {
|
|
596
|
+
return -1;
|
|
597
|
+
}
|
|
598
|
+
if (from < 0) {
|
|
599
|
+
from += length;
|
|
600
|
+
if (from < 0) {
|
|
601
|
+
from = 0;
|
|
602
|
+
}
|
|
603
|
+
}
|
|
604
|
+
for (let i = from; i < length; ++i) {
|
|
605
|
+
if ((0, _primordials.ObjectHasOwn)(float16bitsArray, i) && (0, _converter.convertToNumber)(float16bitsArray[i]) === element) {
|
|
606
|
+
return i;
|
|
607
|
+
}
|
|
608
|
+
}
|
|
609
|
+
return -1;
|
|
610
|
+
}
|
|
611
|
+
lastIndexOf(element, ...opts) {
|
|
612
|
+
assertFloat16Array(this);
|
|
613
|
+
const float16bitsArray = getFloat16BitsArray(this);
|
|
614
|
+
const length = (0, _primordials.TypedArrayPrototypeGetLength)(float16bitsArray);
|
|
615
|
+
let from = opts.length >= 1 ? (0, _spec.ToIntegerOrInfinity)(opts[0]) : length - 1;
|
|
616
|
+
if (from === -Infinity) {
|
|
617
|
+
return -1;
|
|
618
|
+
}
|
|
619
|
+
if (from >= 0) {
|
|
620
|
+
from = from < length - 1 ? from : length - 1;
|
|
621
|
+
} else {
|
|
622
|
+
from += length;
|
|
623
|
+
}
|
|
624
|
+
for (let i = from; i >= 0; --i) {
|
|
625
|
+
if ((0, _primordials.ObjectHasOwn)(float16bitsArray, i) && (0, _converter.convertToNumber)(float16bitsArray[i]) === element) {
|
|
626
|
+
return i;
|
|
627
|
+
}
|
|
628
|
+
}
|
|
629
|
+
return -1;
|
|
630
|
+
}
|
|
631
|
+
includes(element, ...opts) {
|
|
632
|
+
assertFloat16Array(this);
|
|
633
|
+
const float16bitsArray = getFloat16BitsArray(this);
|
|
634
|
+
const length = (0, _primordials.TypedArrayPrototypeGetLength)(float16bitsArray);
|
|
635
|
+
let from = (0, _spec.ToIntegerOrInfinity)(opts[0]);
|
|
636
|
+
if (from === Infinity) {
|
|
637
|
+
return false;
|
|
638
|
+
}
|
|
639
|
+
if (from < 0) {
|
|
640
|
+
from += length;
|
|
641
|
+
if (from < 0) {
|
|
642
|
+
from = 0;
|
|
643
|
+
}
|
|
644
|
+
}
|
|
645
|
+
const isNaN = (0, _primordials.NumberIsNaN)(element);
|
|
646
|
+
for (let i = from; i < length; ++i) {
|
|
647
|
+
const value = (0, _converter.convertToNumber)(float16bitsArray[i]);
|
|
648
|
+
if (isNaN && (0, _primordials.NumberIsNaN)(value)) {
|
|
649
|
+
return true;
|
|
650
|
+
}
|
|
651
|
+
if (value === element) {
|
|
652
|
+
return true;
|
|
653
|
+
}
|
|
654
|
+
}
|
|
655
|
+
return false;
|
|
656
|
+
}
|
|
657
|
+
join(separator) {
|
|
658
|
+
assertFloat16Array(this);
|
|
659
|
+
const float16bitsArray = getFloat16BitsArray(this);
|
|
660
|
+
const array = copyToArray(float16bitsArray);
|
|
661
|
+
return (0, _primordials.ArrayPrototypeJoin)(array, separator);
|
|
662
|
+
}
|
|
663
|
+
toLocaleString(...opts) {
|
|
664
|
+
assertFloat16Array(this);
|
|
665
|
+
const float16bitsArray = getFloat16BitsArray(this);
|
|
666
|
+
const array = copyToArray(float16bitsArray);
|
|
667
|
+
return (0, _primordials.ArrayPrototypeToLocaleString)(array, ...(0, _arrayIterator.safeIfNeeded)(opts));
|
|
668
|
+
}
|
|
669
|
+
get [_primordials.SymbolToStringTag]() {
|
|
670
|
+
if (isFloat16Array(this)) {
|
|
671
|
+
return "Float16Array";
|
|
672
|
+
}
|
|
673
|
+
}
|
|
674
|
+
}
|
|
675
|
+
exports.Float16Array = Float16Array;
|
|
676
|
+
(0, _primordials.ObjectDefineProperty)(Float16Array, "BYTES_PER_ELEMENT", {
|
|
677
|
+
value: BYTES_PER_ELEMENT
|
|
678
|
+
});
|
|
679
|
+
(0, _primordials.ObjectDefineProperty)(Float16Array, _brand.brand, {});
|
|
680
|
+
(0, _primordials.ReflectSetPrototypeOf)(Float16Array, _primordials.TypedArray);
|
|
681
|
+
const Float16ArrayPrototype = Float16Array.prototype;
|
|
682
|
+
(0, _primordials.ObjectDefineProperty)(Float16ArrayPrototype, "BYTES_PER_ELEMENT", {
|
|
683
|
+
value: BYTES_PER_ELEMENT
|
|
684
|
+
});
|
|
685
|
+
(0, _primordials.ObjectDefineProperty)(Float16ArrayPrototype, _primordials.SymbolIterator, {
|
|
686
|
+
value: Float16ArrayPrototype.values,
|
|
687
|
+
writable: true,
|
|
688
|
+
configurable: true
|
|
689
|
+
});
|
|
690
|
+
(0, _primordials.ReflectSetPrototypeOf)(Float16ArrayPrototype, _primordials.TypedArrayPrototype);
|