-
Notifications
You must be signed in to change notification settings - Fork 1
/
out.js
92 lines (91 loc) · 3.22 KB
/
out.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
var $jscomp = $jscomp || {};
$jscomp.scope = {};
$jscomp.ASSUME_ES5 = !1;
$jscomp.ASSUME_NO_NATIVE_MAP = !1;
$jscomp.ASSUME_NO_NATIVE_SET = !1;
$jscomp.SIMPLE_FROUND_POLYFILL = !1;
$jscomp.ISOLATE_POLYFILLS = !1;
$jscomp.FORCE_POLYFILL_PROMISE = !1;
$jscomp.FORCE_POLYFILL_PROMISE_WHEN_NO_UNHANDLED_REJECTION = !1;
$jscomp.defineProperty = $jscomp.ASSUME_ES5 || "function" == typeof Object.defineProperties ? Object.defineProperty : function(a, c, b) {
if (a == Array.prototype || a == Object.prototype) {
return a;
}
a[c] = b.value;
return a;
};
$jscomp.getGlobal = function(a) {
a = ["object" == typeof globalThis && globalThis, a, "object" == typeof window && window, "object" == typeof self && self, "object" == typeof global && global];
for (var c = 0; c < a.length; ++c) {
var b = a[c];
if (b && b.Math == Math) {
return b;
}
}
throw Error("Cannot find global object");
};
$jscomp.global = $jscomp.getGlobal(this);
$jscomp.IS_SYMBOL_NATIVE = "function" === typeof Symbol && "symbol" === typeof Symbol("x");
$jscomp.TRUST_ES6_POLYFILLS = !$jscomp.ISOLATE_POLYFILLS || $jscomp.IS_SYMBOL_NATIVE;
$jscomp.polyfills = {};
$jscomp.propertyToPolyfillSymbol = {};
$jscomp.POLYFILL_PREFIX = "$jscp$";
var $jscomp$lookupPolyfilledValue = function(a, c, b) {
if (!b || null != a) {
b = $jscomp.propertyToPolyfillSymbol[c];
if (null == b) {
return a[c];
}
b = a[b];
return void 0 !== b ? b : a[c];
}
};
$jscomp.polyfill = function(a, c, b, d) {
c && ($jscomp.ISOLATE_POLYFILLS ? $jscomp.polyfillIsolated(a, c, b, d) : $jscomp.polyfillUnisolated(a, c, b, d));
};
$jscomp.polyfillUnisolated = function(a, c, b, d) {
b = $jscomp.global;
a = a.split(".");
for (d = 0; d < a.length - 1; d++) {
var e = a[d];
if (!(e in b)) {
return;
}
b = b[e];
}
a = a[a.length - 1];
d = b[a];
c = c(d);
c != d && null != c && $jscomp.defineProperty(b, a, {configurable:!0, writable:!0, value:c});
};
$jscomp.polyfillIsolated = function(a, c, b, d) {
var e = a.split(".");
a = 1 === e.length;
d = e[0];
d = !a && d in $jscomp.polyfills ? $jscomp.polyfills : $jscomp.global;
for (var g = 0; g < e.length - 1; g++) {
var f = e[g];
if (!(f in d)) {
return;
}
d = d[f];
}
e = e[e.length - 1];
b = $jscomp.IS_SYMBOL_NATIVE && "es6" === b ? d[e] : null;
c = c(b);
null != c && (a ? $jscomp.defineProperty($jscomp.polyfills, e, {configurable:!0, writable:!0, value:c}) : c !== b && (void 0 === $jscomp.propertyToPolyfillSymbol[e] && (b = 1E9 * Math.random() >>> 0, $jscomp.propertyToPolyfillSymbol[e] = $jscomp.IS_SYMBOL_NATIVE ? $jscomp.global.Symbol(e) : $jscomp.POLYFILL_PREFIX + b + "$" + e), $jscomp.defineProperty(d, $jscomp.propertyToPolyfillSymbol[e], {configurable:!0, writable:!0, value:c})));
};
$jscomp.polyfill("String.raw", function(a) {
return a ? a : function(c, b) {
if (null == c) {
throw new TypeError("Cannot convert undefined or null to object");
}
for (var d = c.raw, e = d.length, g = "", f = 0; f < e; ++f) {
g += d[f], f + 1 < e && f + 1 < arguments.length && (g += String(arguments[f + 1]));
}
return g;
};
}, "es6", "es3");
module.exports = function() {
return "a0b1c" === String.raw({raw:["a", "b", "c"]}, 0, 1);
};