Skipped 1 file(s) >100MB (GitHub limit): source/__polyfill/04xxx/module_4759.js (118.4 MB)
33 lines
792 B
JavaScript
33 lines
792 B
JavaScript
// Module ID: 678
|
|
// Function ID: 679
|
|
// Dependencies: []
|
|
// Exports: createSyntheticError, getFramesToPop, isErrorLike
|
|
|
|
// Module 678
|
|
|
|
export const createSyntheticError = function createSyntheticError() {
|
|
let num = arg0;
|
|
if (arg0 === undefined) {
|
|
num = 0;
|
|
}
|
|
const error = new Error();
|
|
error.framesToPop = num + 3;
|
|
return error;
|
|
};
|
|
export const getFramesToPop = function getFramesToPop(syntheticException) {
|
|
let num = 0;
|
|
if (undefined !== syntheticException.framesToPop) {
|
|
num = syntheticException.framesToPop;
|
|
}
|
|
return num;
|
|
};
|
|
export const isErrorLike = function isErrorLike(cause) {
|
|
let tmp = null !== cause && typeof cause === "object";
|
|
if (tmp) {
|
|
tmp = "stack" in cause;
|
|
}
|
|
if (tmp) {
|
|
tmp = typeof cause.stack === "string";
|
|
}
|
|
return tmp;
|
|
};
|