decord/source/16273__isNativeReflectConstruct.js

163 lines
4.1 KiB
JavaScript
Raw Normal View History

2026-07-27 11:26:19 +00:00
// Module ID: 16273
// Function ID: 126297
2026-07-20 16:05:17 +00:00
// Name: _isNativeReflectConstruct
2026-07-23 10:11:24 +00:00
// Dependencies: [7, 6, 16, 15, 17, 18, 162]
2026-07-27 11:26:19 +00:00
// Module 16273 (_isNativeReflectConstruct)
2026-07-23 10:11:24 +00:00
import _defineProperties from "_defineProperties";
import _classCallCheck from "_wrapNativeSuper";
import _assertThisInitialized from "_assertThisInitialized";
import "_possibleConstructorReturn";
import _getPrototypeOf from "_getPrototypeOf";
import _inherits from "_inherits";
import _wrapNativeSuper from "_wrapNativeSuper";
2026-07-20 16:05:17 +00:00
let self = this;
function _isNativeReflectConstruct() {
let closure_0 = !valueOf.call(Reflect.construct(Boolean, [], () => {
}));
function _isNativeReflectConstruct() {
return closure_0;
}
const result = _isNativeReflectConstruct();
}
2026-07-23 10:11:24 +00:00
let fn = function u(exports) {
let tmp = ((arg0) => {
2026-07-20 16:05:17 +00:00
const fn = function t(arg0) {
const self = this;
2026-07-23 10:11:24 +00:00
o(this, fn);
2026-07-20 16:05:17 +00:00
let str = "Timed out";
if (null != arg0) {
const _HermesInternal = HermesInternal;
str = "Timed out after waiting for " + arg0 + " ms";
}
const items = [str];
2026-07-23 10:11:24 +00:00
const obj = outer2_4(fn);
if (outer2_7()) {
2026-07-20 16:05:17 +00:00
const _Reflect = Reflect;
2026-07-23 10:11:24 +00:00
let constructResult = Reflect.construct(obj, items, outer2_4(self).constructor);
2026-07-20 16:05:17 +00:00
} else {
constructResult = obj.apply(self, items);
}
2026-07-23 10:11:24 +00:00
const tmp4Result = POSITIVE_INFINITY(self, constructResult);
Object.setPrototypeOf(callback(tmp4Result), fn.prototype);
2026-07-20 16:05:17 +00:00
return tmp4Result;
};
2026-07-23 10:11:24 +00:00
return outer1_5(fn, arg0)(fn);
})(_wrapNativeSuper(Error));
const _defineProperties = tmp;
2026-07-20 16:05:17 +00:00
function o(arg0, arg1) {
2026-07-23 10:11:24 +00:00
let closure_0 = arg0;
let closure_1 = arg1;
2026-07-20 16:05:17 +00:00
return new Promise((arg0, arg1) => {
2026-07-23 10:11:24 +00:00
closure_0.schedule(arg0, closure_1);
2026-07-20 16:05:17 +00:00
});
}
let closure_2 = {
2026-07-23 10:11:24 +00:00
schedule(arg0, closure_1) {
let closure_0 = arg0;
2026-07-20 16:05:17 +00:00
function n(arg0) {
if (null != arg0) {
const _clearTimeout = clearTimeout;
clearTimeout(arg0);
}
2026-07-23 10:11:24 +00:00
let c1;
2026-07-20 16:05:17 +00:00
}
const timeout = setTimeout(() => {
n(closure_1);
2026-07-23 10:11:24 +00:00
callback();
}, closure_1);
2026-07-20 16:05:17 +00:00
return {
cancel() {
n(closure_1);
}
};
}
};
2026-07-23 10:11:24 +00:00
let fn = function r(arg0, timeout) {
2026-07-20 16:05:17 +00:00
let tmp = arg2;
2026-07-23 10:11:24 +00:00
let closure_0 = arg0;
2026-07-20 16:05:17 +00:00
let tmp3 = timeout;
if ("number" !== typeof timeout) {
timeout = undefined;
if (null != timeout) {
timeout = timeout.timeout;
}
tmp3 = timeout;
}
let num = 5000;
if (null !== tmp3) {
num = 5000;
if (undefined !== tmp3) {
num = tmp3;
}
}
if ("number" !== typeof timeout) {
let prop;
if (null != timeout) {
prop = timeout.intervalBetweenAttempts;
}
tmp = prop;
}
let num2 = 50;
if (null !== tmp) {
num2 = 50;
if (undefined !== tmp) {
num2 = tmp;
}
}
2026-07-23 10:11:24 +00:00
let c3 = false;
let fn = function f() {
2026-07-20 16:05:17 +00:00
return new Promise((arg0, arg1) => {
2026-07-23 10:11:24 +00:00
let closure_0 = arg0;
let closure_1 = arg1;
2026-07-20 16:05:17 +00:00
const fn = function r() {
2026-07-23 10:11:24 +00:00
if (!outer2_3) {
let promise = new Promise(() => { ... });
promise.then(() => { ... }).catch(closure_1);
let nextPromise = promise.then(() => { ... });
2026-07-20 16:05:17 +00:00
}
};
fn();
});
};
let fn2;
2026-07-23 10:11:24 +00:00
if (num !== c3) {
2026-07-20 16:05:17 +00:00
fn2 = () => num(num2, num).then(() => {
2026-07-23 10:11:24 +00:00
const outer1_3 = true;
throw new closure_0(outer1_1);
2026-07-20 16:05:17 +00:00
});
}
if (null != fn2) {
const items = [fn(), fn2()];
let racePromise = Promise.race(items);
} else {
racePromise = fn();
}
return racePromise;
};
exports.DEFAULT_INTERVAL_BETWEEN_ATTEMPTS_IN_MS = 50;
exports.DEFAULT_TIMEOUT_IN_MS = 5000;
exports.TimeoutError = tmp;
exports.WAIT_FOREVER = POSITIVE_INFINITY;
exports.default = fn;
exports.waitUntil = fn;
};
if ("object" === typeof exports) {
if (undefined !== module) {
fn(exports);
}
}
if ("function" === typeof globalThis.define) {
if (globalThis.define.amd) {
2026-07-23 10:11:24 +00:00
globalThis.define(["exports"], fn);
2026-07-20 16:05:17 +00:00
}
}
if ("undefined" !== typeof globalThis) {
self = globalThis;
}
2026-07-23 10:11:24 +00:00
let obj = {};
self["async-wait-until"] = obj;
2026-07-20 16:05:17 +00:00
fn(obj);