mirror of
https://github.com/google/blockly.git
synced 2026-05-09 21:50:12 +02:00
Update JS-Interpreter to latest version.
This commit is contained in:
@@ -1,6 +1,5 @@
|
||||
// Acorn: Copyright 2012 Marijn Haverbeke, MIT License
|
||||
var mod$$inline_58=function(a){function b(a){n=a||{};for(var b in Ua)Object.prototype.hasOwnProperty.call(n,b)||(n[b]=Ua[b]);wa=n.sourceFile||null}function c(a,b){var c=Ab(k,a);b+=" ("+c.line+":"+c.column+")";var d=new SyntaxError(b);d.pos=a;d.loc=c;d.raisedAt=f;throw d;}function d(a){function b(a){if(1==a.length)return c+="return str === "+JSON.stringify(a[0])+";";c+="switch(str){";for(var va=0;va<a.length;++va)c+="case "+JSON.stringify(a[va])+":";c+="return true}return false;"}a=a.split(" ");var c=
|
||||
"",d=[],e=0;a:for(;e<a.length;++e){for(var g=0;g<d.length;++g)if(d[g][0].length==a[e].length){d[g].push(a[e]);continue a}d.push([a[e]])}if(3<d.length){d.sort(function(a,b){return b.length-a.length});c+="switch(str.length){";for(e=0;e<d.length;++e)a=d[e],c+="case "+a[0].length+":",b(a);c+="}"}else b(a);return new Function("str",c)}function e(){this.line=G;this.column=f-D}function g(a,b){X=f;n.locations&&(ia=new e);p=a;l();H=b;R=a.beforeExpr}function h(){for(var a=f,b=n.onComment&&n.locations&&new e,
|
||||
var mod$$inline_58=function(a){function b(a){n=a||{};for(var b in Ua)Object.prototype.hasOwnProperty.call(n,b)||(n[b]=Ua[b]);wa=n.sourceFile||null}function c(a,b){var c=Ab(k,a);b+=" ("+c.line+":"+c.column+")";var d=new SyntaxError(b);d.pos=a;d.loc=c;d.raisedAt=f;throw d;}function d(a){a=a.split(" ");for(var c=Object.create(null),b=0;b<a.length;b++)c[a[b]]=!0;return function(d){return c[d]||!1}}function e(){this.line=G;this.column=f-D}function g(a,b){X=f;n.locations&&(ia=new e);p=a;l();H=b;R=a.beforeExpr}function h(){for(var a=f,b=n.onComment&&n.locations&&new e,
|
||||
c=k.charCodeAt(f+=2);f<S&&10!==c&&13!==c&&8232!==c&&8233!==c;)++f,c=k.charCodeAt(f);if(n.onComment)n.onComment(!1,k.slice(a+2,f),a,f,b,n.locations&&new e)}function l(){for(;f<S;){var a=k.charCodeAt(f);if(32===a)++f;else if(13===a)++f,a=k.charCodeAt(f),10===a&&++f,n.locations&&(++G,D=f);else if(10===a||8232===a||8233===a)++f,n.locations&&(++G,D=f);else if(8<a&&14>a)++f;else if(47===a)if(a=k.charCodeAt(f+1),42===a){var a=n.onComment&&n.locations&&new e,b=f,d=k.indexOf("*/",f+=2);-1===d&&c(f-2,"Unterminated comment");
|
||||
f=d+2;if(n.locations){Y.lastIndex=b;for(var g=void 0;(g=Y.exec(k))&&g.index<f;)++G,D=g.index+g[0].length}if(n.onComment)n.onComment(!0,k.slice(b+2,d),b,f,a,n.locations&&new e)}else if(47===a)h();else break;else if(160===a)++f;else if(5760<=a&&Bb.test(String.fromCharCode(a)))++f;else break}}function m(a){switch(a){case 46:return a=k.charCodeAt(f+1),48<=a&&57>=a?a=P(!0):(++f,a=g(xa)),a;case 40:return++f,g(I);case 41:return++f,g(E);case 59:return++f,g(J);case 44:return++f,g(L);case 91:return++f,g(ja);
|
||||
case 93:return++f,g(ka);case 123:return++f,g(Z);case 125:return++f,g(T);case 58:return++f,g(aa);case 63:return++f,g(ya);case 48:if(a=k.charCodeAt(f+1),120===a||88===a)return f+=2,a=B(16),null==a&&c(x+2,"Expected hexadecimal number"),la(k.charCodeAt(f))&&c(f,"Identifier directly after number"),a=g(ba,a);case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:return P(!1);case 34:case 39:a:{f++;for(var b="";;){f>=S&&c(x,"Unterminated string constant");var d=k.charCodeAt(f);if(d===a){++f;
|
||||
@@ -38,106 +37,121 @@ Pb=RegExp("[\u00aa\u00b5\u00ba\u00c0-\u00d6\u00d8-\u00f6\u00f8-\u02c1\u02c6-\u02
|
||||
na=/[\n\r\u2028\u2029]/,Y=/\r\n|[\n\r\u2028\u2029]/g,la=a.isIdentifierStart=function(a){return 65>a?36===a:91>a?!0:97>a?95===a:123>a?!0:170<=a&&Za.test(String.fromCharCode(a))},ab=a.isIdentifierChar=function(a){return 48>a?36===a:58>a?!0:65>a?!1:91>a?!0:97>a?95===a:123>a?!0:170<=a&&Pb.test(String.fromCharCode(a))},ca,Ia={kind:"loop"},Ob={kind:"switch"}};
|
||||
"object"==typeof exports&&"object"==typeof module?mod$$inline_58(exports):"function"==typeof define&&define.amd?define(["exports"],mod$$inline_58):mod$$inline_58(this.acorn||(this.acorn={}));
|
||||
// JS-Interpreter: Copyright 2013 Google LLC, Apache 2.0
|
||||
function u(a,b){"string"===typeof a&&(a=acorn.parse(a,ha));this.Ha=a.constructor;var c=new this.Ha({options:{}});for(d in a)c[d]="body"===d?a[d].slice():a[d];this.fa=c;this.kb=b;this.wa=!1;this.U=[];this.Sa=0;this.pb=Object.create(null);var d=/^step([A-Z]\w*)$/;var e,g;for(g in this)"function"===typeof this[g]&&(e=g.match(d))&&(this.pb[e[1]]=this[g].bind(this));this.M=ia(this,this.fa,null);this.Da=this.M.object;this.fa=acorn.parse(this.U.join("\n"),ha);this.U=void 0;ra(this.fa,void 0,void 0);e=new v(this.fa,
|
||||
this.M);e.done=!1;this.j=[e];this.nb();this.value=void 0;this.fa=c;e=new v(this.fa,this.M);e.done=!1;this.j.length=0;this.j[0]=e;this.stateStack=this.j}
|
||||
var ha={Ca:5},ya={configurable:!0,enumerable:!0,writable:!1},B={configurable:!0,enumerable:!1,writable:!0},E={configurable:!0,enumerable:!1,writable:!1},za={configurable:!1,enumerable:!0,writable:!0},Aa={STEP_ERROR:!0},Ba={SCOPE_REFERENCE:!0},Ia={VALUE_IN_DESCRIPTOR:!0},Ja={REGEXP_TIMEOUT:!0},Ka=[],La=null,Ma=["onmessage = function(e) {","var result;","var data = e.data;","switch (data[0]) {","case 'split':","result = data[1].split(data[2], data[3]);","break;","case 'match':","result = data[1].match(data[2]);",
|
||||
"break;","case 'search':","result = data[1].search(data[2]);","break;","case 'replace':","result = data[1].replace(data[2], data[3]);","break;","case 'exec':","var regexp = data[1];","regexp.lastIndex = data[2];","result = [regexp.exec(data[3]), data[1].lastIndex];","break;","default:","throw 'Unknown RegExp operation: ' + data[0];","}","postMessage(result);","};"];function Na(a){var b=a>>>0;return b===Number(a)?b:NaN}function Oa(a){var b=a>>>0;return String(b)===String(a)&&4294967295!==b?b:NaN}
|
||||
function ra(a,b,c){b?a.start=b:delete a.start;c?a.end=c:delete a.end;for(var d in a)if(a.hasOwnProperty(d)){var e=a[d];e&&"object"===typeof e&&ra(e,b,c)}}u.prototype.REGEXP_MODE=2;u.prototype.REGEXP_THREAD_TIMEOUT=1E3;q=u.prototype;q.I=!1;q.ya=!1;
|
||||
q.ub=function(a){var b=this.j[0];if(!b||"Program"!==b.node.type)throw Error("Expecting original AST to start with a Program node.");"string"===typeof a&&(a=acorn.parse(a,ha));if(!a||"Program"!==a.type)throw Error("Expecting new AST to start with a Program node.");Pa(this,a,b.scope);Array.prototype.push.apply(b.node.body,a.body);b.done=!1};
|
||||
q.step=function(){var a=this.j;do{var b=a[a.length-1];if(!b)return!1;var c=b.node,d=c.type;if("Program"===d&&b.done)return!1;if(this.wa)break;try{var e=this.pb[d](a,b,c)}catch(g){if(g!==Aa)throw g;}e&&a.push(e);if(this.I)throw Error("Getter not supported in this context");if(this.ya)throw Error("Setter not supported in this context");}while(!c.end);return!0};q.nb=function(){for(;!this.wa&&this.step(););return this.wa};
|
||||
function Qa(a,b){a.setProperty(b,"NaN",NaN,ya);a.setProperty(b,"Infinity",Infinity,ya);a.setProperty(b,"undefined",void 0,ya);a.setProperty(b,"window",b,ya);a.setProperty(b,"this",b,ya);a.setProperty(b,"self",b);a.B=new F(null);a.W=new F(a.B);db(a,b);eb(a,b);b.la=a.B;a.setProperty(b,"constructor",a.m,B);Fb(a,b);Gb(a,b);Hb(a,b);Ib(a,b);Jb(a,b);Kb(a,b);Lb(a,b);Mb(a,b);Nb(a,b);var c=a.b(function(){throw EvalError("Can't happen");},!1);c.eval=!0;a.setProperty(b,"eval",c);a.setProperty(b,"parseInt",a.b(parseInt,
|
||||
!1));a.setProperty(b,"parseFloat",a.b(parseFloat,!1));a.setProperty(b,"isNaN",a.b(isNaN,!1));a.setProperty(b,"isFinite",a.b(isFinite,!1));c=[[escape,"escape"],[unescape,"unescape"],[decodeURI,"decodeURI"],[decodeURIComponent,"decodeURIComponent"],[encodeURI,"encodeURI"],[encodeURIComponent,"encodeURIComponent"]];for(var d=0;d<c.length;d++)a.setProperty(b,c[d][1],a.b(function(e){return function(g){try{return e(g)}catch(n){I(a,a.rb,n.message)}}}(c[d][0]),!1),B);a.OBJECT=a.m;a.OBJECT_PROTO=a.B;a.FUNCTION=
|
||||
a.H;a.FUNCTION_PROTO=a.W;a.ARRAY=a.l;a.ARRAY_PROTO=a.za;a.REGEXP=a.C;a.REGEXP_PROTO=a.Aa;a.DATE=a.R;a.DATE_PROTO=a.Za;a.kb&&a.kb(a,b)}
|
||||
function db(a,b){function c(g){if(!(g instanceof F||Ob(a).P))if(void 0===g||null===g)g=a.Da;else{var n=a.h(Pb(a,g));n.data=g;g=n}return g}var d=/^[A-Za-z_$][\w$]*$/;var e=function(g){var n=arguments.length?String(arguments[arguments.length-1]):"",p=Array.prototype.slice.call(arguments,0,-1).join(",").trim();if(p){p=p.split(/\s*,\s*/);for(var z=0;z<p.length;z++){var A=p[z];d.test(A)||I(a,a.da,"Invalid function argument: "+A)}p=p.join(", ")}try{var C=acorn.parse("(function("+p+") {"+n+"})",ha)}catch(ja){I(a,
|
||||
a.da,"Invalid code: "+ja.message)}1!==C.body.length&&I(a,a.da,"Invalid code in function body.");return xc(a,C.body[0].expression,a.M)};a.H=a.b(e,!0);a.setProperty(b,"Function",a.H);a.setProperty(a.H,"prototype",a.W,B);a.setProperty(a.W,"constructor",a.H,B);a.W.Ga=function(){};a.W.Ga.id=a.Sa++;a.setProperty(a.W,"length",0,E);e=function(g,n){var p=a.j[a.j.length-1];p.Z=this;p.G=c(g);p.A=[];null!==n&&void 0!==n&&(n instanceof F?p.A=yc(a,n):I(a,a.g,"CreateListFromArrayLike called on non-object"));p.Ra=
|
||||
!1};N(a,a.H,"apply",e);e=function(g){var n=a.j[a.j.length-1];n.Z=this;n.G=c(g);n.A=[];for(var p=1;p<arguments.length;p++)n.A.push(arguments[p]);n.Ra=!1};N(a,a.H,"call",e);a.U.push("Object.defineProperty(Function.prototype, 'bind',","{configurable: true, writable: true, value:","function(oThis) {","if (typeof this !== 'function') {","throw TypeError('What is trying to be bound is not callable');","}","var aArgs = Array.prototype.slice.call(arguments, 1),","fToBind = this,","fNOP = function() {},",
|
||||
"fBound = function() {","return fToBind.apply(this instanceof fNOP","? this",": oThis,","aArgs.concat(Array.prototype.slice.call(arguments)));","};","if (this.prototype) {","fNOP.prototype = this.prototype;","}","fBound.prototype = new fNOP();","return fBound;","}","});","");e=function(){return String(this)};N(a,a.H,"toString",e);a.setProperty(a.H,"toString",a.b(e,!1),B);e=function(){return this.valueOf()};N(a,a.H,"valueOf",e);a.setProperty(a.H,"valueOf",a.b(e,!1),B)}
|
||||
function eb(a,b){function c(e){void 0!==e&&null!==e||I(a,a.g,"Cannot convert '"+e+"' to object")}var d=function(e){if(void 0===e||null===e)return zc(a)?this:a.h(a.B);if(!(e instanceof F)){var g=a.h(Pb(a,e));g.data=e;return g}return e};a.m=a.b(d,!0);a.setProperty(a.m,"prototype",a.B,B);a.setProperty(a.B,"constructor",a.m,B);a.setProperty(b,"Object",a.m);d=function(e){c(e);return T(a,Object.getOwnPropertyNames(e instanceof F?e.a:e))};a.setProperty(a.m,"getOwnPropertyNames",a.b(d,!1),B);d=function(e){c(e);
|
||||
e instanceof F&&(e=e.a);return T(a,Object.keys(e))};a.setProperty(a.m,"keys",a.b(d,!1),B);d=function(e){if(null===e)return a.h(null);e instanceof F||I(a,a.g,"Object prototype may only be an Object or null");return a.h(e)};a.setProperty(a.m,"create",a.b(d,!1),B);a.U.push("(function() {","var create_ = Object.create;","Object.create = function(proto, props) {","var obj = create_(proto);","props && Object.defineProperties(obj, props);","return obj;","};","})();","");d=function(e,g,n){g=String(g);e instanceof
|
||||
F||I(a,a.g,"Object.defineProperty called on non-object");n instanceof F||I(a,a.g,"Property description must be an object");!e.a[g]&&e.preventExtensions&&I(a,a.g,"Can't define property '"+g+"', object is not extensible");a.setProperty(e,g,Ia,n.a);return e};a.setProperty(a.m,"defineProperty",a.b(d,!1),B);a.U.push("(function() {","var defineProperty_ = Object.defineProperty;","Object.defineProperty = function(obj, prop, d1) {","var d2 = {};","if ('configurable' in d1) d2.configurable = d1.configurable;",
|
||||
"if ('enumerable' in d1) d2.enumerable = d1.enumerable;","if ('writable' in d1) d2.writable = d1.writable;","if ('value' in d1) d2.value = d1.value;","if ('get' in d1) d2.get = d1.get;","if ('set' in d1) d2.set = d1.set;","return defineProperty_(obj, prop, d2);","};","})();","Object.defineProperty(Object, 'defineProperties',","{configurable: true, writable: true, value:","function(obj, props) {","var keys = Object.keys(props);","for (var i = 0; i < keys.length; i++) {","Object.defineProperty(obj, keys[i], props[keys[i]]);",
|
||||
"}","return obj;","}","});","");d=function(e,g){e instanceof F||I(a,a.g,"Object.getOwnPropertyDescriptor called on non-object");g=String(g);if(g in e.a){var n=Object.getOwnPropertyDescriptor(e.a,g),p=e.L[g],z=e.O[g],A=a.h(a.B);p||z?(a.setProperty(A,"get",p),a.setProperty(A,"set",z)):(a.setProperty(A,"value",n.value),a.setProperty(A,"writable",n.writable));a.setProperty(A,"configurable",n.configurable);a.setProperty(A,"enumerable",n.enumerable);return A}};a.setProperty(a.m,"getOwnPropertyDescriptor",
|
||||
a.b(d,!1),B);d=function(e){c(e);return Pb(a,e)};a.setProperty(a.m,"getPrototypeOf",a.b(d,!1),B);d=function(e){return!!e&&!e.preventExtensions};a.setProperty(a.m,"isExtensible",a.b(d,!1),B);d=function(e){e instanceof F&&(e.preventExtensions=!0);return e};a.setProperty(a.m,"preventExtensions",a.b(d,!1),B);N(a,a.m,"toString",F.prototype.toString);N(a,a.m,"toLocaleString",F.prototype.toString);N(a,a.m,"valueOf",F.prototype.valueOf);d=function(e){c(this);return this instanceof F?String(e)in this.a:this.hasOwnProperty(e)};
|
||||
N(a,a.m,"hasOwnProperty",d);d=function(e){c(this);return this instanceof F?Object.prototype.propertyIsEnumerable.call(this.a,e):this.propertyIsEnumerable(e)};N(a,a.m,"propertyIsEnumerable",d);d=function(e){for(;;){e=Pb(a,e);if(!e)return!1;if(e===this)return!0}};N(a,a.m,"isPrototypeOf",d)}
|
||||
function Fb(a,b){var c=function(d){var e=zc(a)?this:Ac(a),g=arguments[0];if(1===arguments.length&&"number"===typeof g)isNaN(Na(g))&&I(a,a.$a,"Invalid array length"),e.a.length=g;else{for(g=0;g<arguments.length;g++)e.a[g]=arguments[g];e.a.length=g}return e};a.l=a.b(c,!0);a.za=a.l.a.prototype;a.setProperty(b,"Array",a.l);c=function(d){return d&&"Array"===d.F};a.setProperty(a.l,"isArray",a.b(c,!1),B);a.setProperty(a.za,"length",0,{configurable:!1,enumerable:!1,writable:!0});a.za.F="Array";N(a,a.l,"pop",
|
||||
function(){return Array.prototype.pop.call(this.a)});c=function(d){return Array.prototype.push.apply(this.a,arguments)};N(a,a.l,"push",c);N(a,a.l,"shift",function(){return Array.prototype.shift.call(this.a)});c=function(d){return Array.prototype.unshift.apply(this.a,arguments)};N(a,a.l,"unshift",c);N(a,a.l,"reverse",function(){Array.prototype.reverse.call(this.a);return this});c=function(d,e){var g=Array.prototype.splice.apply(this.a,arguments);return T(a,g)};N(a,a.l,"splice",c);c=function(d,e){return T(a,
|
||||
Array.prototype.slice.call(this.a,d,e))};N(a,a.l,"slice",c);c=function(d){return Array.prototype.join.call(this.a,d)};N(a,a.l,"join",c);c=function(d){for(var e=[],g=0,n=a.u(this,"length"),p=0;p<n;p++){if(Bc(a,this,p)){var z=a.u(this,p);e[g]=z}g++}for(p=0;p<arguments.length;p++)if(n=arguments[p],U(a,n,a.l)){z=a.u(n,"length");for(var A=0;A<z;A++)Bc(a,n,A)&&(e[g]=a.u(n,A)),g++}else e[g]=n;return T(a,e)};N(a,a.l,"concat",c);c=function(d,e){return Array.prototype.indexOf.apply(this.a,arguments)};N(a,a.l,
|
||||
"indexOf",c);c=function(d,e){return Array.prototype.lastIndexOf.apply(this.a,arguments)};N(a,a.l,"lastIndexOf",c);N(a,a.l,"sort",function(){Array.prototype.sort.call(this.a);return this});a.U.push("Object.defineProperty(Array.prototype, 'every',","{configurable: true, writable: true, value:","function(callbackfn, thisArg) {","if (!this || typeof callbackfn !== 'function') throw TypeError();","var T, k;","var O = Object(this);","var len = O.length >>> 0;","if (arguments.length > 1) T = thisArg;","k = 0;",
|
||||
"while (k < len) {","if (k in O && !callbackfn.call(T, O[k], k, O)) return false;","k++;","}","return true;","}","});","Object.defineProperty(Array.prototype, 'filter',","{configurable: true, writable: true, value:","function(fun/*, thisArg*/) {","if (this === void 0 || this === null || typeof fun !== 'function') throw TypeError();","var t = Object(this);","var len = t.length >>> 0;","var res = [];","var thisArg = arguments.length >= 2 ? arguments[1] : void 0;","for (var i = 0; i < len; i++) {","if (i in t) {",
|
||||
"var val = t[i];","if (fun.call(thisArg, val, i, t)) res.push(val);","}","}","return res;","}","});","Object.defineProperty(Array.prototype, 'forEach',","{configurable: true, writable: true, value:","function(callback, thisArg) {","if (!this || typeof callback !== 'function') throw TypeError();","var T, k;","var O = Object(this);","var len = O.length >>> 0;","if (arguments.length > 1) T = thisArg;","k = 0;","while (k < len) {","if (k in O) callback.call(T, O[k], k, O);","k++;","}","}","});","Object.defineProperty(Array.prototype, 'map',",
|
||||
"{configurable: true, writable: true, value:","function(callback, thisArg) {","if (!this || typeof callback !== 'function') new TypeError;","var T, A, k;","var O = Object(this);","var len = O.length >>> 0;","if (arguments.length > 1) T = thisArg;","A = new Array(len);","k = 0;","while (k < len) {","if (k in O) A[k] = callback.call(T, O[k], k, O);","k++;","}","return A;","}","});","Object.defineProperty(Array.prototype, 'reduce',","{configurable: true, writable: true, value:","function(callback /*, initialValue*/) {",
|
||||
"if (!this || typeof callback !== 'function') throw TypeError();","var t = Object(this), len = t.length >>> 0, k = 0, value;","if (arguments.length === 2) {","value = arguments[1];","} else {","while (k < len && !(k in t)) k++;","if (k >= len) {","throw TypeError('Reduce of empty array with no initial value');","}","value = t[k++];","}","for (; k < len; k++) {","if (k in t) value = callback(value, t[k], k, t);","}","return value;","}","});","Object.defineProperty(Array.prototype, 'reduceRight',",
|
||||
"{configurable: true, writable: true, value:","function(callback /*, initialValue*/) {","if (null === this || 'undefined' === typeof this || 'function' !== typeof callback) throw TypeError();","var t = Object(this), len = t.length >>> 0, k = len - 1, value;","if (arguments.length >= 2) {","value = arguments[1];","} else {","while (k >= 0 && !(k in t)) k--;","if (k < 0) {","throw TypeError('Reduce of empty array with no initial value');","}","value = t[k--];","}","for (; k >= 0; k--) {","if (k in t) value = callback(value, t[k], k, t);",
|
||||
"}","return value;","}","});","Object.defineProperty(Array.prototype, 'some',","{configurable: true, writable: true, value:","function(fun/*, thisArg*/) {","if (!this || typeof fun !== 'function') throw TypeError();","var t = Object(this);","var len = t.length >>> 0;","var thisArg = arguments.length >= 2 ? arguments[1] : void 0;","for (var i = 0; i < len; i++) {","if (i in t && fun.call(thisArg, t[i], i, t)) {","return true;","}","}","return false;","}","});","(function() {","var sort_ = Array.prototype.sort;",
|
||||
"Array.prototype.sort = function(opt_comp) {","if (typeof opt_comp !== 'function') {","return sort_.call(this);","}","for (var i = 0; i < this.length; i++) {","var changes = 0;","for (var j = 0; j < this.length - i - 1; j++) {","if (opt_comp(this[j], this[j + 1]) > 0) {","var swap = this[j];","this[j] = this[j + 1];","this[j + 1] = swap;","changes++;","}","}","if (!changes) break;","}","return this;","};","})();","Object.defineProperty(Array.prototype, 'toLocaleString',","{configurable: true, writable: true, value:",
|
||||
"function() {","var out = [];","for (var i = 0; i < this.length; i++) {","out[i] = (this[i] === null || this[i] === undefined) ? '' : this[i].toLocaleString();","}","return out.join(',');","}","});","")}
|
||||
function Gb(a,b){var c=function(e){e=arguments.length?String(e):"";return zc(a)?(this.data=e,this):e};a.w=a.b(c,!0);a.setProperty(b,"String",a.w);a.setProperty(a.w,"fromCharCode",a.b(String.fromCharCode,!1),B);c="charAt charCodeAt concat indexOf lastIndexOf slice substr substring toLocaleLowerCase toLocaleUpperCase toLowerCase toUpperCase trim".split(" ");for(var d=0;d<c.length;d++)N(a,a.w,c[d],String.prototype[c[d]]);c=function(e,g,n){g=g?a.J(g):void 0;n=n?a.J(n):void 0;return String(this).localeCompare(e,
|
||||
g,n)};N(a,a.w,"localeCompare",c);c=function(e,g,n){var p=String(this);g=g?Number(g):void 0;if(U(a,e,a.C)&&(e=e.data,Cc(a,e,n),2===a.REGEXP_MODE)){if(La)e=Dc(a,"string.split(separator, limit)",{string:p,separator:e,limit:g},e,n),e!==Ja&&n(T(a,e));else{var z=a.X(),A=Uc(a,e,z,n);z.onmessage=function(C){clearTimeout(A);n(T(a,C.data))};z.postMessage(["split",p,e,g])}return}e=p.split(e,g);n(T(a,e))};Vc(a,a.w,"split",c);c=function(e,g){var n=String(this);e=U(a,e,a.C)?e.data:new RegExp(e);Cc(a,e,g);if(2===
|
||||
a.REGEXP_MODE)if(La)n=Dc(a,"string.match(regexp)",{string:n,regexp:e},e,g),n!==Ja&&g(n&&T(a,n));else{var p=a.X(),z=Uc(a,e,p,g);p.onmessage=function(A){clearTimeout(z);g(A.data&&T(a,A.data))};p.postMessage(["match",n,e])}else n=n.match(e),g(n&&T(a,n))};Vc(a,a.w,"match",c);c=function(e,g){var n=String(this);e=U(a,e,a.C)?e.data:new RegExp(e);Cc(a,e,g);if(2===a.REGEXP_MODE)if(La)n=Dc(a,"string.search(regexp)",{string:n,regexp:e},e,g),n!==Ja&&g(n);else{var p=a.X(),z=Uc(a,e,p,g);p.onmessage=function(A){clearTimeout(z);
|
||||
g(A.data)};p.postMessage(["search",n,e])}else g(n.search(e))};Vc(a,a.w,"search",c);c=function(e,g,n){var p=String(this);g=String(g);if(U(a,e,a.C)&&(e=e.data,Cc(a,e,n),2===a.REGEXP_MODE)){if(La)e=Dc(a,"string.replace(substr, newSubstr)",{string:p,substr:e,newSubstr:g},e,n),e!==Ja&&n(e);else{var z=a.X(),A=Uc(a,e,z,n);z.onmessage=function(C){clearTimeout(A);n(C.data)};z.postMessage(["replace",p,e,g])}return}n(p.replace(e,g))};Vc(a,a.w,"replace",c);a.U.push("(function() {","var replace_ = String.prototype.replace;",
|
||||
"String.prototype.replace = function(substr, newSubstr) {","if (typeof newSubstr !== 'function') {","return replace_.call(this, substr, newSubstr);","}","var str = this;","if (substr instanceof RegExp) {","var subs = [];","var m = substr.exec(str);","while (m) {","m.push(m.index, str);","var inject = newSubstr.apply(null, m);","subs.push([m.index, m[0].length, inject]);","m = substr.global ? substr.exec(str) : null;","}","for (var i = subs.length - 1; i >= 0; i--) {","str = str.substring(0, subs[i][0]) + subs[i][2] + str.substring(subs[i][0] + subs[i][1]);",
|
||||
"}","} else {","var i = str.indexOf(substr);","if (i !== -1) {","var inject = newSubstr(str.substr(i, substr.length), i, str);","str = str.substring(0, i) + inject + str.substring(i + substr.length);","}","}","return str;","};","})();","")}function Hb(a,b){a.Ya=a.b(function(c){c=!!c;return zc(a)?(this.data=c,this):c},!0);a.setProperty(b,"Boolean",a.Ya)}
|
||||
function Ib(a,b){var c=function(e){e=arguments.length?Number(e):0;return zc(a)?(this.data=e,this):e};a.S=a.b(c,!0);a.setProperty(b,"Number",a.S);c=["MAX_VALUE","MIN_VALUE","NaN","NEGATIVE_INFINITY","POSITIVE_INFINITY"];for(var d=0;d<c.length;d++)a.setProperty(a.S,c[d],Number[c[d]],E);c=function(e){try{return Number(this).toExponential(e)}catch(g){I(a,a.v,g.message)}};N(a,a.S,"toExponential",c);c=function(e){try{return Number(this).toFixed(e)}catch(g){I(a,a.v,g.message)}};N(a,a.S,"toFixed",c);c=function(e){try{return Number(this).toPrecision(e)}catch(g){I(a,
|
||||
a.v,g.message)}};N(a,a.S,"toPrecision",c);c=function(e){try{return Number(this).toString(e)}catch(g){I(a,a.v,g.message)}};N(a,a.S,"toString",c);c=function(e,g){e=e?a.J(e):void 0;g=g?a.J(g):void 0;return Number(this).toLocaleString(e,g)};N(a,a.S,"toLocaleString",c)}
|
||||
function Jb(a,b){var c=function(g,n){if(!zc(a))return Date();var p=[null].concat(Array.from(arguments));this.data=new (Function.prototype.bind.apply(Date,p));return this};a.R=a.b(c,!0);a.Za=a.R.a.prototype;a.setProperty(b,"Date",a.R);a.setProperty(a.R,"now",a.b(Date.now,!1),B);a.setProperty(a.R,"parse",a.b(Date.parse,!1),B);a.setProperty(a.R,"UTC",a.b(Date.UTC,!1),B);for(var d="getDate getDay getFullYear getHours getMilliseconds getMinutes getMonth getSeconds getTime getTimezoneOffset getUTCDate getUTCDay getUTCFullYear getUTCHours getUTCMilliseconds getUTCMinutes getUTCMonth getUTCSeconds getYear setDate setFullYear setHours setMilliseconds setMinutes setMonth setSeconds setTime setUTCDate setUTCFullYear setUTCHours setUTCMilliseconds setUTCMinutes setUTCMonth setUTCSeconds setYear toDateString toISOString toJSON toGMTString toLocaleDateString toLocaleString toLocaleTimeString toTimeString toUTCString".split(" "),
|
||||
e=0;e<d.length;e++)c=function(g){return function(n){for(var p=[],z=0;z<arguments.length;z++)p[z]=a.J(arguments[z]);return this.data[g].apply(this.data,p)}}(d[e]),N(a,a.R,d[e],c)}
|
||||
function Kb(a,b){var c=function(d,e){var g=zc(a)?this:a.h(a.Aa);d=d?String(d):"";e=e?String(e):"";Wc(a,g,new RegExp(d,e));return g};a.C=a.b(c,!0);a.Aa=a.C.a.prototype;a.setProperty(b,"RegExp",a.C);a.setProperty(a.C.a.prototype,"global",void 0,E);a.setProperty(a.C.a.prototype,"ignoreCase",void 0,E);a.setProperty(a.C.a.prototype,"multiline",void 0,E);a.setProperty(a.C.a.prototype,"source","(?:)",E);a.U.push("Object.defineProperty(RegExp.prototype, 'test',","{configurable: true, writable: true, value:",
|
||||
"function(str) {","return String(str).search(this) !== -1","}","});");c=function(d,e){function g(C){if(C){var ja=T(a,C);a.setProperty(ja,"index",C.index);a.setProperty(ja,"input",C.input);return ja}return null}var n=this.data;d=String(d);n.lastIndex=Number(a.u(this,"lastIndex"));Cc(a,n,e);if(2===a.REGEXP_MODE)if(La){var p=Dc(a,"regexp.exec(string)",{string:d,regexp:n},n,e);p!==Ja&&(a.setProperty(this,"lastIndex",n.lastIndex),e(g(p)))}else{p=a.X();var z=Uc(a,n,p,e),A=this;p.onmessage=function(C){clearTimeout(z);
|
||||
a.setProperty(A,"lastIndex",C.data[1]);e(g(C.data[0]))};p.postMessage(["exec",n,n.lastIndex,d])}else p=n.exec(d),a.setProperty(this,"lastIndex",n.lastIndex),e(g(p))};Vc(a,a.C,"exec",c)}
|
||||
function Lb(a,b){function c(d){var e=a.b(function(g){var n=zc(a)?this:a.ma(e);g&&a.setProperty(n,"message",String(g),B);return n},!0);a.setProperty(e,"prototype",a.ma(a.v),B);a.setProperty(e.a.prototype,"name",d,B);a.setProperty(b,d,e);return e}a.v=a.b(function(d){var e=zc(a)?this:a.ma(a.v);d&&a.setProperty(e,"message",String(d),B);return e},!0);a.setProperty(b,"Error",a.v);a.setProperty(a.v.a.prototype,"message","",B);a.setProperty(a.v.a.prototype,"name","Error",B);c("EvalError");a.$a=c("RangeError");
|
||||
a.ab=c("ReferenceError");a.da=c("SyntaxError");a.g=c("TypeError");a.rb=c("URIError")}function Mb(a,b){var c=a.h(a.B);a.setProperty(b,"Math",c);for(var d="E LN2 LN10 LOG2E LOG10E PI SQRT1_2 SQRT2".split(" "),e=0;e<d.length;e++)a.setProperty(c,d[e],Math[d[e]],E);d="abs acos asin atan atan2 ceil cos exp floor log max min pow random round sin sqrt tan".split(" ");for(e=0;e<d.length;e++)a.setProperty(c,d[e],a.b(Math[d[e]],!1),B)}
|
||||
function Nb(a,b){function c(e){try{var g=JSON.parse(String(e))}catch(n){I(a,a.da,n.message)}return a.ua(g)}var d=a.h(a.B);a.setProperty(b,"JSON",d);a.setProperty(d,"parse",a.b(c,!1));c=function(e,g,n){g&&"Function"===g.F?I(a,a.g,"Function replacer on JSON.stringify not supported"):g&&"Array"===g.F?(g=yc(a,g),g=g.filter(function(z){return"string"===typeof z||"number"===typeof z})):g=null;"string"!==typeof n&&"number"!==typeof n&&(n=void 0);e=a.J(e);try{var p=JSON.stringify(e,g,n)}catch(z){I(a,a.g,
|
||||
z.message)}return p};a.setProperty(d,"stringify",a.b(c,!1))}function U(a,b,c){if(null===b||void 0===b||!c)return!1;c=c.a.prototype;if(b===c)return!0;for(b=Pb(a,b);b;){if(b===c)return!0;b=b.la}return!1}function Wc(a,b,c){b.data=new RegExp(c.source,c.flags);a.setProperty(b,"lastIndex",c.lastIndex,B);a.setProperty(b,"source",c.source,E);a.setProperty(b,"global",c.global,E);a.setProperty(b,"ignoreCase",c.ignoreCase,E);a.setProperty(b,"multiline",c.multiline,E)}
|
||||
q.X=function(){var a=this.X.vb;a||(a=new Blob([Ma.join("\n")],{type:"application/javascript"}),this.X.vb=a);return new Worker(URL.createObjectURL(a))};function Dc(a,b,c,d,e){var g={timeout:a.REGEXP_THREAD_TIMEOUT};try{return La.runInNewContext(b,c,g)}catch(n){e(null),I(a,a.v,"RegExp Timeout: "+d)}return Ja}
|
||||
function Cc(a,b,c){if(0===a.REGEXP_MODE)var d=!1;else if(1===a.REGEXP_MODE)d=!0;else if(La)d=!0;else if("function"===typeof Worker&&"function"===typeof URL)d=!0;else if("function"===typeof require){try{La=require("vm")}catch(e){}d=!!La}else d=!1;d||(c(null),I(a,a.v,"Regular expressions not supported: "+b))}function Uc(a,b,c,d){return setTimeout(function(){c.terminate();d(null);try{I(a,a.v,"RegExp Timeout: "+b)}catch(e){}},a.REGEXP_THREAD_TIMEOUT)}q.ma=function(a){return this.h(a&&a.a.prototype)};
|
||||
q.h=function(a){if("object"!==typeof a)throw Error("Non object prototype");a=new F(a);U(this,a,this.v)&&(a.F="Error");return a};function Ac(a){var b=a.h(a.za);a.setProperty(b,"length",0,{configurable:!1,enumerable:!1,writable:!0});b.F="Array";return b}function Xc(a,b,c){var d=a.h(a.W);c?(c=a.h(a.B),a.setProperty(d,"prototype",c,B),a.setProperty(c,"constructor",d,B)):d.Hb=!0;a.setProperty(d,"length",b,E);d.F="Function";return d}
|
||||
function xc(a,b,c){a=Xc(a,b.params.length,!0);a.va=c;a.node=b;return a}q.b=function(a,b){var c=Xc(this,a.length,b);c.Ga=a;a.id=this.Sa++;return c};q.eb=function(a){var b=Xc(this,a.length,!0);b.Ma=a;a.id=this.Sa++;return b};
|
||||
q.ua=function(a){if(a instanceof F)throw Error("Object is already pseudo");if("object"!==typeof a&&"function"!==typeof a||null===a)return a;if(a instanceof RegExp){var b=this.h(this.Aa);Wc(this,b,a);return b}if(a instanceof Date)return b=this.h(this.Za),b.data=new Date(a.valueOf()),b;if("function"===typeof a){var c=this;return this.b(function(){var e=Array.prototype.slice.call(arguments).map(function(g){return c.J(g)});e=a.apply(c,e);return c.ua(e)},!!Object.getOwnPropertyDescriptor(a,"prototype"))}if(Array.isArray(a)){b=
|
||||
Ac(this);for(var d=0;d<a.length;d++)d in a&&this.setProperty(b,d,this.ua(a[d]));return b}b=this.h(this.B);for(d in a)this.setProperty(b,d,this.ua(a[d]));return b};
|
||||
q.J=function(a,b){if("object"!==typeof a&&"function"!==typeof a||null===a)return a;if(!(a instanceof F))throw Error("Object is not pseudo");if(U(this,a,this.C)){var c=new RegExp(a.data.source,a.data.flags);c.lastIndex=a.data.lastIndex;return c}if(U(this,a,this.R))return new Date(a.data.valueOf());c=b||{Va:[],Fa:[]};var d=c.Va.indexOf(a);if(-1!==d)return c.Fa[d];c.Va.push(a);if(U(this,a,this.l)){var e=[];c.Fa.push(e);var g=this.u(a,"length");for(d=0;d<g;d++)Bc(this,a,d)&&(e[d]=this.J(this.u(a,d),c))}else for(g in e=
|
||||
{},c.Fa.push(e),a.a)"__proto__"!==g&&(d=a.a[g],e[g]=this.J(d,c));c.Va.pop();c.Fa.pop();return e};function T(a,b){for(var c=Ac(a),d=Object.getOwnPropertyNames(b),e=0;e<d.length;e++)a.setProperty(c,d[e],b[d[e]]);return c}function yc(a,b){var c=[],d;for(d in b.a)c[d]=a.u(b,d);c.length=Na(a.u(b,"length"))||0;return c}function Pb(a,b){switch(typeof b){case "number":return a.S.a.prototype;case "boolean":return a.Ya.a.prototype;case "string":return a.w.a.prototype}return b?b.la:null}
|
||||
q.u=function(a,b){if(this.I)throw Error("Getter not supported in that context");b=String(b);void 0!==a&&null!==a||I(this,this.g,"Cannot read property '"+b+"' of "+a);if("object"===typeof a&&!(a instanceof F))throw TypeError("Expecting native value or pseudo object");if("length"===b){if(U(this,a,this.w))return String(a).length}else if(64>b.charCodeAt(0)&&U(this,a,this.w)){var c=Oa(b);if(!isNaN(c)&&c<String(a).length)return String(a)[c]}do if(a.a&&b in a.a)return(c=a.L[b])?(this.I=!0,c):a.a[b];while(a=
|
||||
Pb(this,a))};function Bc(a,b,c){if(!(b instanceof F))throw TypeError("Primitive data type has no properties");c=String(c);if("length"===c&&U(a,b,a.w))return!0;if(U(a,b,a.w)){var d=Oa(c);if(!isNaN(d)&&d<String(b).length)return!0}do if(b.a&&c in b.a)return!0;while(b=Pb(a,b));return!1}
|
||||
q.setProperty=function(a,b,c,d){if(this.ya)throw Error("Setter not supported in that context");b=String(b);void 0!==a&&null!==a||I(this,this.g,"Cannot set property '"+b+"' of "+a);if("object"===typeof a&&!(a instanceof F))throw TypeError("Expecting native value or pseudo object");d&&("get"in d||"set"in d)&&("value"in d||"writable"in d)&&I(this,this.g,"Invalid property descriptor. Cannot both specify accessors and a value or writable attribute");var e=!this.j||Ob(this).P;if(a instanceof F){if(U(this,
|
||||
a,this.w)){var g=Oa(b);if("length"===b||!isNaN(g)&&g<String(a).length){e&&I(this,this.g,"Cannot assign to read only property '"+b+"' of String '"+a.data+"'");return}}if("Array"===a.F)if(g=a.a.length,"length"===b){if(d){if(!("value"in d))return;c=d.value}c=Na(c);isNaN(c)&&I(this,this.$a,"Invalid array length");if(c<g)for(n in a.a){var n=Oa(n);!isNaN(n)&&c<=n&&delete a.a[n]}}else isNaN(n=Oa(b))||(a.a.length=Math.max(g,n+1));if(!a.preventExtensions||b in a.a)if(d){"get"in d&&(d.get?a.L[b]=d.get:delete a.L[b]);
|
||||
"set"in d&&(d.set?a.O[b]=d.set:delete a.O[b]);e={};"configurable"in d&&(e.configurable=d.configurable);"enumerable"in d&&(e.enumerable=d.enumerable);"writable"in d&&(e.writable=d.writable,delete a.L[b],delete a.O[b]);"value"in d?(e.value=d.value,delete a.L[b],delete a.O[b]):c!==Ia&&(e.value=c,delete a.L[b],delete a.O[b]);try{Object.defineProperty(a.a,b,e)}catch(p){I(this,this.g,"Cannot redefine property: "+b)}}else{if(c===Ia)throw ReferenceError("Value not specified.");for(d=a;!(b in d.a);)if(d=Pb(this,
|
||||
d),!d){d=a;break}if(d.O&&d.O[b])return this.ya=!0,d.O[b];if(d.L&&d.L[b])e&&I(this,this.g,"Cannot set property '"+b+"' of object '"+a+"' which only has a getter");else try{a.a[b]=c}catch(p){e&&I(this,this.g,"Cannot assign to read only property '"+b+"' of object '"+a+"'")}}else e&&I(this,this.g,"Can't add property '"+b+"', object is not extensible")}else e&&I(this,this.g,"Can't create property '"+b+"' on '"+a+"'")};function N(a,b,c,d){a.setProperty(b.a.prototype,c,a.b(d,!1),B)}
|
||||
function Vc(a,b,c,d){a.setProperty(b.a.prototype,c,a.eb(d),B)}function Ob(a){a=a.j[a.j.length-1].scope;if(!a)throw Error("No scope found.");return a}function ia(a,b,c){var d=!1;if(c&&c.P)d=!0;else{var e=b.body&&b.body[0];e&&e.qa&&"Literal"===e.qa.type&&"use strict"===e.qa.value&&(d=!0)}e=a.h(null);d=new Yc(c,d,e);c||Qa(a,d.object);Pa(a,b,d);return d}function Zc(a,b,c){if(!b)throw Error("parentScope required");a=c||a.h(null);return new Yc(b,b.P,a)}
|
||||
function $c(a,b){for(var c=Ob(a);c&&c!==a.M;){if(b in c.object.a)return c.object.a[b];c=c.va}if(c===a.M&&Bc(a,c.object,b))return a.u(c.object,b);c=a.j[a.j.length-1].node;"UnaryExpression"===c.type&&"typeof"===c.operator||I(a,a.ab,b+" is not defined")}function ad(a,b,c){for(var d=Ob(a),e=d.P;d&&d!==a.M;){if(b in d.object.a){d.object.a[b]=c;return}d=d.va}if(d===a.M&&(!e||Bc(a,d.object,b)))return a.setProperty(d.object,b,c);I(a,a.ab,b+" is not defined")}
|
||||
function Pa(a,b,c){if("VariableDeclaration"===b.type)for(var d=0;d<b.declarations.length;d++)a.setProperty(c.object,b.declarations[d].id.name,void 0,za);else{if("FunctionDeclaration"===b.type){a.setProperty(c.object,b.id.name,xc(a,b,c),za);return}if("FunctionExpression"===b.type||"ExpressionStatement"===b.type)return}var e=b.constructor,g;for(g in b){var n=b[g];if(n&&"object"===typeof n)if(Array.isArray(n))for(d=0;d<n.length;d++)n[d]&&n[d].constructor===e&&Pa(a,n[d],c);else n.constructor===e&&Pa(a,
|
||||
n,c)}}function zc(a){return a.j[a.j.length-1].isConstructor}function bd(a,b){return b[0]===Ba?$c(a,b[1]):a.u(b[0],b[1])}function cd(a,b,c){return b[0]===Ba?ad(a,b[1],c):a.setProperty(b[0],b[1],c)}function I(a,b,c){void 0!==c&&(b=a.ma(b),a.setProperty(b,"message",c,B));dd(a,4,b,void 0);throw Aa;}
|
||||
function dd(a,b,c,d){if(0===b)throw TypeError("Should not unwind for NORMAL completions");var e=a.j;a:for(;0<e.length;e.pop()){var g=e[e.length-1];switch(g.node.type){case "TryStatement":g.T={type:b,value:c,label:d};return;case "CallExpression":case "NewExpression":if(3===b){g.value=c;return}if(4!==b)throw Error("Unsynatctic break/continue not rejected by Acorn");break;case "Program":g.done=!0;break a}if(1===b){if(d?g.labels&&-1!==g.labels.indexOf(d):g.N||g.Jb){e.pop();return}}else if(2===b&&(d?g.labels&&
|
||||
-1!==g.labels.indexOf(d):g.N))return}U(a,c,a.v)?(b={EvalError:EvalError,RangeError:RangeError,ReferenceError:ReferenceError,SyntaxError:SyntaxError,TypeError:TypeError,URIError:URIError},d=String(a.u(c,"name")),a=a.u(c,"message").valueOf(),a=(b[d]||Error)(a)):a=String(c);throw a;}
|
||||
function ed(a,b,c){if(!a.I)throw Error("Unexpected call to createGetter");a.I=!1;c=Array.isArray(c)?c[0]:c;var d=new a.Ha({options:{}});d.type="CallExpression";a=new v(d,a.j[a.j.length-1].scope);a.ha=!0;a.G=c;a.Z=b;a.Qa=!0;a.A=[];return a}function fd(a,b,c,d){if(!a.ya)throw Error("Unexpected call to createSetter");a.ya=!1;c=Array.isArray(c)?c[0]:a.Da;var e=new a.Ha({options:{}});e.type="CallExpression";a=new v(e,a.j[a.j.length-1].scope);a.ha=!0;a.G=c;a.Z=b;a.Qa=!0;a.A=[d];return a}
|
||||
function v(a,b){this.node=a;this.scope=b}function Yc(a,b,c){this.va=a;this.P=b;this.object=c}function F(a){this.L=Object.create(null);this.O=Object.create(null);this.a=Object.create(null);this.la=a}q=F.prototype;q.la=null;q.F="Object";q.data=null;
|
||||
q.toString=function(){if(!(this instanceof F))return String(this);if("Array"===this.F){var a=Ka;a.push(this);try{for(var b=[],c=0;c<this.a.length;c++){var d=this.a[c];b[c]=d instanceof F&&-1!==a.indexOf(d)?"...":d}}finally{a.pop()}return b.join(",")}if("Error"===this.F){a=Ka;if(-1!==a.indexOf(this))return"[object Error]";d=this;do if("name"in d.a){b=d.a.name;break}while(d=d.la);d=this;do if("message"in d.a){c=d.a.message;break}while(d=d.la);a.push(this);try{b=b&&String(b),c=c&&String(c)}finally{a.pop()}return c?
|
||||
b+": "+c:String(b)}return null!==this.data?String(this.data):"[object "+this.F+"]"};q.valueOf=function(){return void 0===this.data||null===this.data||this.data instanceof RegExp?this:this.data instanceof Date?this.data.valueOf():this.data};u.prototype.stepArrayExpression=function(a,b,c){c=c.elements;var d=b.o||0;b.Ba?(this.setProperty(b.Ba,d,b.value),d++):(b.Ba=Ac(this),b.Ba.a.length=c.length);for(;d<c.length;){if(c[d])return b.o=d,new v(c[d],b.scope);d++}a.pop();a[a.length-1].value=b.Ba};
|
||||
u.prototype.stepAssignmentExpression=function(a,b,c){if(!b.Y)return b.Y=!0,b=new v(c.left,b.scope),b.ga=!0,b;if(!b.pa){b.ra||(b.ra=b.value);b.na&&(b.$=b.value);if(!b.na&&"="!==c.operator&&(a=bd(this,b.ra),b.$=a,this.I))return b.na=!0,ed(this,a,b.ra);b.pa=!0;return new v(c.right,b.scope)}if(b.ia)a.pop(),a[a.length-1].value=b.Wa;else{var d=b.$,e=b.value;switch(c.operator){case "=":d=e;break;case "+=":d+=e;break;case "-=":d-=e;break;case "*=":d*=e;break;case "/=":d/=e;break;case "%=":d%=e;break;case "<<=":d<<=
|
||||
e;break;case ">>=":d>>=e;break;case ">>>=":d>>>=e;break;case "&=":d&=e;break;case "^=":d^=e;break;case "|=":d|=e;break;default:throw SyntaxError("Unknown assignment expression: "+c.operator);}if(c=cd(this,b.ra,d))return b.ia=!0,b.Wa=d,fd(this,c,b.ra,d);a.pop();a[a.length-1].value=d}};
|
||||
u.prototype.stepBinaryExpression=function(a,b,c){if(!b.Y)return b.Y=!0,new v(c.left,b.scope);if(!b.pa)return b.pa=!0,b.$=b.value,new v(c.right,b.scope);a.pop();var d=b.$;b=b.value;switch(c.operator){case "==":c=d==b;break;case "!=":c=d!=b;break;case "===":c=d===b;break;case "!==":c=d!==b;break;case ">":c=d>b;break;case ">=":c=d>=b;break;case "<":c=d<b;break;case "<=":c=d<=b;break;case "+":c=d+b;break;case "-":c=d-b;break;case "*":c=d*b;break;case "/":c=d/b;break;case "%":c=d%b;break;case "&":c=d&
|
||||
b;break;case "|":c=d|b;break;case "^":c=d^b;break;case "<<":c=d<<b;break;case ">>":c=d>>b;break;case ">>>":c=d>>>b;break;case "in":b instanceof F||I(this,this.g,"'in' expects an object, not '"+b+"'");c=Bc(this,b,d);break;case "instanceof":U(this,b,this.H)||I(this,this.g,"Right-hand side of instanceof is not an object");c=d instanceof F?U(this,d,b):!1;break;default:throw SyntaxError("Unknown binary operator: "+c.operator);}a[a.length-1].value=c};
|
||||
u.prototype.stepBlockStatement=function(a,b,c){var d=b.o||0;if(c=c.body[d])return b.o=d+1,new v(c,b.scope);a.pop()};u.prototype.stepBreakStatement=function(a,b,c){dd(this,1,void 0,c.label&&c.label.name)};
|
||||
u.prototype.stepCallExpression=function(a,b,c){if(!b.ha){b.ha=1;var d=new v(c.callee,b.scope);d.ga=!0;return d}if(1===b.ha){b.ha=2;d=b.value;if(Array.isArray(d)){if(b.Z=bd(this,d),d[0]===Ba?b.yb="eval"===d[1]:b.G=d[0],d=b.Z,this.I)return b.ha=1,ed(this,d,b.value)}else b.Z=d;b.A=[];b.o=0}d=b.Z;if(!b.Qa){0!==b.o&&b.A.push(b.value);if(c.arguments[b.o])return new v(c.arguments[b.o++],b.scope);if("NewExpression"===c.type){d.Hb&&I(this,this.g,d+" is not a constructor");if(d===this.l)b.G=Ac(this);else{var e=
|
||||
d.a.prototype;if("object"!==typeof e||null===e)e=this.B;b.G=this.h(e)}b.isConstructor=!0}else void 0===b.G&&(b.G=b.scope.P?void 0:this.Da);b.Qa=!0}if(b.Ra)a.pop(),a[a.length-1].value=b.isConstructor&&"object"!==typeof b.value?b.G:b.value;else{b.Ra=!0;d instanceof F||I(this,this.g,d+" is not a function");if(a=d.node){c=ia(this,a.body,d.va);for(var g=0;g<a.params.length;g++)this.setProperty(c.object,a.params[g].name,b.A.length>g?b.A[g]:void 0);e=Ac(this);for(g=0;g<b.A.length;g++)this.setProperty(e,
|
||||
g,b.A[g]);this.setProperty(c.object,"arguments",e);(g=a.id&&a.id.name)&&this.setProperty(c.object,g,d);this.setProperty(c.object,"this",b.G,ya);b.value=void 0;return new v(a.body,c)}if(d.eval)if(d=b.A[0],"string"!==typeof d)b.value=d;else{try{g=acorn.parse(String(d),ha)}catch(p){I(this,this.da,"Invalid code: "+p.message)}d=new this.Ha({options:{}});d.type="EvalProgram_";d.body=g.body;ra(d,c.start,c.end);c=b.yb?b.scope:this.M;c.P?c=ia(this,g,c):Pa(this,g,c);this.value=void 0;return new v(d,c)}else if(d.Ga)b.value=
|
||||
d.Ga.apply(b.G,b.A);else if(d.Ma){var n=this;g=d.Ma.length-1;g=b.A.concat(Array(g)).slice(0,g);g.push(function(p){b.value=p;n.wa=!1});this.wa=!0;d.Ma.apply(b.G,g)}else I(this,this.g,d.F+" is not callable")}};u.prototype.stepCatchClause=function(a,b,c){if(b.K)a.pop();else return b.K=!0,a=Zc(this,b.scope),this.setProperty(a.object,c.param.name,b.Qb),new v(c.body,a)};
|
||||
u.prototype.stepConditionalExpression=function(a,b,c){var d=b.ba||0;if(0===d)return b.ba=1,new v(c.test,b.scope);if(1===d){b.ba=2;if((d=!!b.value)&&c.consequent)return new v(c.consequent,b.scope);if(!d&&c.alternate)return new v(c.alternate,b.scope);this.value=void 0}a.pop();"ConditionalExpression"===c.type&&(a[a.length-1].value=b.value)};u.prototype.stepContinueStatement=function(a,b,c){dd(this,2,void 0,c.label&&c.label.name)};u.prototype.stepDebuggerStatement=function(a){a.pop()};
|
||||
u.prototype.stepDoWhileStatement=function(a,b,c){"DoWhileStatement"===c.type&&void 0===b.V&&(b.value=!0,b.V=!0);if(!b.V)return b.V=!0,new v(c.test,b.scope);if(!b.value)a.pop();else if(c.body)return b.V=!1,b.N=!0,new v(c.body,b.scope)};u.prototype.stepEmptyStatement=function(a){a.pop()};u.prototype.stepEvalProgram_=function(a,b,c){var d=b.o||0;if(c=c.body[d])return b.o=d+1,new v(c,b.scope);a.pop();a[a.length-1].value=this.value};
|
||||
u.prototype.stepExpressionStatement=function(a,b,c){if(!b.K)return b.K=!0,new v(c.expression,b.scope);a.pop();this.value=b.value};
|
||||
u.prototype.stepForInStatement=function(a,b,c){if(!b.Db&&(b.Db=!0,c.left.declarations&&c.left.declarations[0].init))return b.scope.P&&I(this,this.da,"for-in loop variable declaration may not have an initializer."),new v(c.left,b.scope);if(!b.oa)return b.oa=!0,b.ca||(b.ca=b.value),new v(c.right,b.scope);b.N||(b.N=!0,b.i=b.value,b.Xa=Object.create(null));if(void 0===b.Ea)a:for(;;){if(b.i instanceof F)for(b.ka||(b.ka=Object.getOwnPropertyNames(b.i.a));;){var d=b.ka.shift();if(void 0===d)break;if(Object.prototype.hasOwnProperty.call(b.i.a,
|
||||
d)&&!b.Xa[d]&&(b.Xa[d]=!0,Object.prototype.propertyIsEnumerable.call(b.i.a,d))){b.Ea=d;break a}}else if(null!==b.i&&void 0!==b.i)for(b.ka||(b.ka=Object.getOwnPropertyNames(b.i));;){d=b.ka.shift();if(void 0===d)break;b.Xa[d]=!0;if(Object.prototype.propertyIsEnumerable.call(b.i,d)){b.Ea=d;break a}}b.i=Pb(this,b.i);b.ka=null;if(null===b.i){a.pop();return}}if(!b.hb)if(b.hb=!0,a=c.left,"VariableDeclaration"===a.type)b.ca=[Ba,a.declarations[0].id.name];else return b.ca=null,b=new v(a,b.scope),b.ga=!0,b;
|
||||
b.ca||(b.ca=b.value);if(!b.ia&&(b.ia=!0,a=b.Ea,d=cd(this,b.ca,a)))return fd(this,d,b.ca,a);b.Ea=void 0;b.hb=!1;b.ia=!1;if(c.body)return new v(c.body,b.scope)};u.prototype.stepForStatement=function(a,b,c){var d=b.ba||0;if(0===d){if(b.ba=1,c.init)return new v(c.init,b.scope)}else if(1===d){if(b.ba=2,c.test)return new v(c.test,b.scope)}else if(2===d)if(b.ba=3,c.test&&!b.value)a.pop();else return b.N=!0,new v(c.body,b.scope);else if(3===d&&(b.ba=1,c.update))return new v(c.update,b.scope)};
|
||||
u.prototype.stepFunctionDeclaration=function(a){a.pop()};u.prototype.stepFunctionExpression=function(a,b,c){a.pop();a[a.length-1].value=xc(this,c,b.scope)};u.prototype.stepIdentifier=function(a,b,c){a.pop();if(b.ga)a[a.length-1].value=[Ba,c.name];else{var d=$c(this,c.name);if(this.I){for(a=b.scope;!Bc(this,a,c.name);)a=a.va;return ed(this,d,this.Da)}a[a.length-1].value=d}};u.prototype.stepIfStatement=u.prototype.stepConditionalExpression;
|
||||
u.prototype.stepLabeledStatement=function(a,b,c){a.pop();a=b.labels||[];a.push(c.label.name);b=new v(c.body,b.scope);b.labels=a;return b};u.prototype.stepLiteral=function(a,b,c){a.pop();b=c.value;b instanceof RegExp&&(c=this.h(this.Aa),Wc(this,c,b),b=c);a[a.length-1].value=b};
|
||||
u.prototype.stepLogicalExpression=function(a,b,c){if("&&"!==c.operator&&"||"!==c.operator)throw SyntaxError("Unknown logical operator: "+c.operator);if(!b.Y)return b.Y=!0,new v(c.left,b.scope);if(b.pa)a.pop(),a[a.length-1].value=b.value;else if("&&"===c.operator&&!b.value||"||"===c.operator&&b.value)a.pop(),a[a.length-1].value=b.value;else return b.pa=!0,new v(c.right,b.scope)};
|
||||
u.prototype.stepMemberExpression=function(a,b,c){if(!b.oa)return b.oa=!0,new v(c.object,b.scope);if(c.computed)if(b.Eb)c=b.value;else return b.i=b.value,b.Eb=!0,new v(c.property,b.scope);else b.i=b.value,c=c.property.name;a.pop();if(b.ga)a[a.length-1].value=[b.i,c];else{c=this.u(b.i,c);if(this.I)return ed(this,c,b.i);a[a.length-1].value=c}};u.prototype.stepNewExpression=u.prototype.stepCallExpression;
|
||||
u.prototype.stepObjectExpression=function(a,b,c){var d=b.o||0,e=c.properties[d];if(b.i){var g=e.key;if("Identifier"===g.type)var n=g.name;else if("Literal"===g.type)n=g.value;else throw SyntaxError("Unknown object structure: "+g.type);b.xa[n]||(b.xa[n]={});b.xa[n][e.kind]=b.value;b.o=++d;e=c.properties[d]}else b.i=this.h(this.B),b.xa=Object.create(null);if(e)return new v(e.value,b.scope);for(g in b.xa)c=b.xa[g],"get"in c||"set"in c?this.setProperty(b.i,g,Ia,{configurable:!0,enumerable:!0,get:c.get,
|
||||
set:c.set}):this.setProperty(b.i,g,c.init);a.pop();a[a.length-1].value=b.i};u.prototype.stepProgram=function(a,b,c){if(a=c.body.shift())return b.done=!1,new v(a,b.scope);b.done=!0};u.prototype.stepReturnStatement=function(a,b,c){if(c.argument&&!b.K)return b.K=!0,new v(c.argument,b.scope);dd(this,3,b.value,void 0)};u.prototype.stepSequenceExpression=function(a,b,c){var d=b.o||0;if(c=c.expressions[d])return b.o=d+1,new v(c,b.scope);a.pop();a[a.length-1].value=b.value};
|
||||
u.prototype.stepSwitchStatement=function(a,b,c){if(!b.V)return b.V=1,new v(c.discriminant,b.scope);1===b.V&&(b.V=2,b.Pb=b.value,b.Pa=-1);for(;;){var d=b.Ta||0,e=c.cases[d];if(b.ta||!e||e.test)if(e||b.ta||-1===b.Pa)if(e){if(!b.ta&&!b.qb&&e.test)return b.qb=!0,new v(e.test,b.scope);if(b.ta||b.value===b.Pb){b.ta=!0;var g=b.o||0;if(e.consequent[g])return b.Jb=!0,b.o=g+1,new v(e.consequent[g],b.scope)}b.qb=!1;b.o=0;b.Ta=d+1}else{a.pop();break}else b.ta=!0,b.Ta=b.Pa;else b.Pa=d,b.Ta=d+1}};
|
||||
u.prototype.stepThisExpression=function(a){a.pop();a[a.length-1].value=$c(this,"this")};u.prototype.stepThrowStatement=function(a,b,c){if(b.K)I(this,b.value);else return b.K=!0,new v(c.argument,b.scope)};
|
||||
u.prototype.stepTryStatement=function(a,b,c){if(!b.zb)return b.zb=!0,new v(c.block,b.scope);if(b.T&&4===b.T.type&&!b.Cb&&c.handler)return b.Cb=!0,a=new v(c.handler,b.scope),a.Qb=b.T.value,b.T=void 0,a;if(!b.Bb&&c.finalizer)return b.Bb=!0,new v(c.finalizer,b.scope);a.pop();b.T&&dd(this,b.T.type,b.T.value,b.T.label)};
|
||||
u.prototype.stepUnaryExpression=function(a,b,c){if(!b.K)return b.K=!0,a=new v(c.argument,b.scope),a.ga="delete"===c.operator,a;a.pop();var d=b.value;if("-"===c.operator)d=-d;else if("+"===c.operator)d=+d;else if("!"===c.operator)d=!d;else if("~"===c.operator)d=~d;else if("delete"===c.operator){c=!0;if(Array.isArray(d)){var e=d[0];e===Ba&&(e=b.scope);d=String(d[1]);try{delete e.a[d]}catch(g){b.scope.P?I(this,this.g,"Cannot delete property '"+d+"' of '"+e+"'"):c=!1}}d=c}else if("typeof"===c.operator)d=
|
||||
d&&"Function"===d.F?"function":typeof d;else if("void"===c.operator)d=void 0;else throw SyntaxError("Unknown unary operator: "+c.operator);a[a.length-1].value=d};
|
||||
u.prototype.stepUpdateExpression=function(a,b,c){if(!b.Y)return b.Y=!0,a=new v(c.argument,b.scope),a.ga=!0,a;b.sa||(b.sa=b.value);b.na&&(b.$=b.value);if(!b.na){var d=bd(this,b.sa);b.$=d;if(this.I)return b.na=!0,ed(this,d,b.sa)}if(b.ia)a.pop(),a[a.length-1].value=b.Wa;else{d=Number(b.$);if("++"===c.operator)var e=d+1;else if("--"===c.operator)e=d-1;else throw SyntaxError("Unknown update expression: "+c.operator);c=c.prefix?e:d;if(d=cd(this,b.sa,e))return b.ia=!0,b.Wa=c,fd(this,d,b.sa,e);a.pop();a[a.length-
|
||||
1].value=c}};u.prototype.stepVariableDeclaration=function(a,b,c){c=c.declarations;var d=b.o||0,e=c[d];b.lb&&e&&(ad(this,e.id.name,b.value),b.lb=!1,e=c[++d]);for(;e;){if(e.init)return b.o=d,b.lb=!0,new v(e.init,b.scope);e=c[++d]}a.pop()};u.prototype.stepWithStatement=function(a,b,c){if(b.oa)if(b.Ab)a.pop();else return b.Ab=!0,a=Zc(this,b.scope,b.value),new v(c.body,a);else return b.oa=!0,new v(c.object,b.scope)};u.prototype.stepWhileStatement=u.prototype.stepDoWhileStatement;this.Interpreter=u;
|
||||
u.prototype.step=u.prototype.step;u.prototype.run=u.prototype.nb;u.prototype.appendCode=u.prototype.ub;u.prototype.createObject=u.prototype.ma;u.prototype.createObjectProto=u.prototype.h;u.prototype.createAsyncFunction=u.prototype.eb;u.prototype.createNativeFunction=u.prototype.b;u.prototype.getProperty=u.prototype.u;u.prototype.setProperty=u.prototype.setProperty;u.prototype.nativeToPseudo=u.prototype.ua;u.prototype.pseudoToNative=u.prototype.J;u.prototype.createPrimitive=function(a){return a};
|
||||
function r(a,b){"string"===typeof a&&(a=Ga(a,"code"));this.Ga=a.constructor;var d=new this.Ga({options:{}}),c;for(c in a)d[c]="body"===c?a[c].slice():a[c];this.ka=d;this.kb=b;this.sa=!1;this.$=[];this.Ra=0;this.lb=Object.create(null);a=/^step([A-Z]\w*)$/;var e,g;for(g in this)"function"===typeof this[g]&&(e=g.match(a))&&(this.lb[e[1]]=this[g].bind(this));this.R=Ha(this,this.ka,null);this.Sa=this.R.object;this.ka=Ga(this.$.join("\n"),"polyfills");this.$=void 0;Ia(this.ka,void 0,void 0);e=new t(this.ka,
|
||||
this.R);e.done=!1;this.o=[e];this.xb();this.value=void 0;this.ka=d;e=new t(this.ka,this.R);e.done=!1;this.o.length=0;this.o[0]=e}
|
||||
var Ja={locations:!0,ecmaVersion:5},Ka={configurable:!0,enumerable:!0,writable:!1},u={configurable:!0,enumerable:!1,writable:!0},B={configurable:!0,enumerable:!1,writable:!1},La={configurable:!1,enumerable:!1,writable:!1},Ma={configurable:!1,enumerable:!0,writable:!0},Na={STEP_ERROR:!0},Oa={SCOPE_REFERENCE:!0},Pa={VALUE_IN_DESCRIPTOR:!0},Qa={REGEXP_TIMEOUT:!0},eb=[],fb=null,gb="undefined"===typeof globalThis?this:globalThis,Gb=["onmessage = function(e) {","var result;","var data = e.data;","switch (data[0]) {",
|
||||
"case 'split':","result = data[1].split(data[2], data[3]);","break;","case 'match':","result = data[1].match(data[2]);","break;","case 'search':","result = data[1].search(data[2]);","break;","case 'replace':","result = data[1].replace(data[2], data[3]);","break;","case 'exec':","var regexp = data[1];","regexp.lastIndex = data[2];","result = [regexp.exec(data[3]), data[1].lastIndex];","break;","default:","throw Error('Unknown RegExp operation: ' + data[0]);","}","postMessage(result);","};"];
|
||||
function Hb(a){var b=a>>>0;return b===Number(a)?b:NaN}function Ib(a){var b=a>>>0;return String(b)===String(a)&&4294967295!==b?b:NaN}function Ia(a,b,d){b?a.start=b:delete a.start;d?a.end=d:delete a.end;for(var c in a)if("loc"!==c&&a.hasOwnProperty(c)){var e=a[c];e&&"object"===typeof e&&Ia(e,b,d)}}r.prototype.REGEXP_MODE=2;r.prototype.REGEXP_THREAD_TIMEOUT=1E3;r.prototype.POLYFILL_TIMEOUT=1E3;p=r.prototype;p.N=!1;p.Da=!1;p.Cb=0;
|
||||
function Ga(a,b){var d={},c;for(c in Ja)d[c]=Ja[c];d.sourceFile=b;return acorn.parse(a,d)}p.Bb=function(a){var b=this.o[0];if(!b||"Program"!==b.node.type)throw Error("Expecting original AST to start with a Program node.");"string"===typeof a&&(a=Ga(a,"appendCode"+this.Cb++));if(!a||"Program"!==a.type)throw Error("Expecting new AST to start with a Program node.");Jb(this,a,b.scope);Array.prototype.push.apply(b.node.body,a.body);b.done=!1};
|
||||
p.fb=function(){var a=this.o,b=Date.now();do{var d=a[a.length-1];if(!d)return!1;var c=d.node,e=c.type;if("Program"===e&&d.done)return!1;if(this.sa)break;try{var g=this.lb[e](a,d,c)}catch(l){if(l!==Na)throw l;}g&&a.push(g);if(this.N)throw Error("Getter not supported in this context");if(this.Da)throw Error("Setter not supported in this context");}while(!c.end&&b+this.POLYFILL_TIMEOUT>Date.now());return!0};p.xb=function(){for(;!this.sa&&this.fb(););return this.sa};
|
||||
function Kb(a,b){a.g(b,"NaN",NaN,La);a.g(b,"Infinity",Infinity,La);a.g(b,"undefined",void 0,La);a.g(b,"window",b,Ka);a.g(b,"this",b,La);a.g(b,"self",b);a.L=new C(null);a.X=new C(a.L);Lb(a,b);Mb(a,b);b.ra=a.L;a.g(b,"constructor",a.v,u);Nb(a,b);Ob(a,b);Pb(a,b);Qb(a,b);Rb(a,b);Sb(a,b);Tb(a,b);Ub(a,b);Cc(a,b);var d=a.i(function(){throw EvalError("Can't happen");},!1);d.eval=!0;a.g(b,"eval",d,u);a.g(b,"parseInt",a.i(parseInt,!1),u);a.g(b,"parseFloat",a.i(parseFloat,!1),u);a.g(b,"isNaN",a.i(isNaN,!1),u);
|
||||
a.g(b,"isFinite",a.i(isFinite,!1),u);d=[[escape,"escape"],[unescape,"unescape"],[decodeURI,"decodeURI"],[decodeURIComponent,"decodeURIComponent"],[encodeURI,"encodeURI"],[encodeURIComponent,"encodeURIComponent"]];for(var c=0;c<d.length;c++)a.g(b,d[c][1],a.i(function(e){return function(g){try{return e(g)}catch(l){J(a,a.zb,l.message)}}}(d[c][0]),!1),u);a.OBJECT=a.v;a.OBJECT_PROTO=a.L;a.FUNCTION=a.M;a.FUNCTION_PROTO=a.X;a.ARRAY=a.ia;a.ARRAY_PROTO=a.Ea;a.REGEXP=a.I;a.REGEXP_PROTO=a.Fa;a.DATE=a.Y;a.DATE_PROTO=
|
||||
a.hb;a.kb&&a.kb(a,b)}p.Pb=0;
|
||||
function Lb(a,b){var d=/^[A-Za-z_$][\w$]*$/;var c=function(e){var g=arguments.length?String(arguments[arguments.length-1]):"",l=Array.prototype.slice.call(arguments,0,-1).join(",").trim();if(l){l=l.split(/\s*,\s*/);for(var v=0;v<l.length;v++){var E=l[v];d.test(E)||J(a,a.ja,"Invalid function argument: "+E)}l=l.join(", ")}try{var M=Ga("(function("+l+") {"+g+"})","function"+a.Pb++)}catch(D){J(a,a.ja,"Invalid code: "+D.message)}1!==M.body.length&&J(a,a.ja,"Invalid code in function body.");return Dc(a,
|
||||
M.body[0].expression,a.R,"anonymous")};a.M=a.i(c,!0);a.g(b,"Function",a.M,u);a.g(a.M,"prototype",a.X,u);a.g(a.X,"constructor",a.M,u);a.X.La=function(){};a.X.La.id=a.Ra++;a.X.ub=!0;a.g(a.X,"length",0,B);a.X.H="Function";c=function(e,g){var l=a.o[a.o.length-1];l.ba=this;l.B=e;l.G=[];null!==g&&void 0!==g&&(g instanceof C?l.G=Ec(a,g):J(a,a.m,"CreateListFromArrayLike called on non-object"));l.Ya=!1};L(a,a.M,"apply",c);c=function(e){var g=a.o[a.o.length-1];g.ba=this;g.B=e;g.G=[];for(var l=1;l<arguments.length;l++)g.G.push(arguments[l]);
|
||||
g.Ya=!1};L(a,a.M,"call",c);a.$.push("Object.defineProperty(Function.prototype, 'bind',","{configurable: true, writable: true, value:","function bind(oThis) {","if (typeof this !== 'function') {","throw TypeError('What is trying to be bound is not callable');","}","var aArgs = Array.prototype.slice.call(arguments, 1),","fToBind = this,","fNOP = function() {},","fBound = function() {","return fToBind.apply(this instanceof fNOP","? this",": oThis,","aArgs.concat(Array.prototype.slice.call(arguments)));",
|
||||
"};","if (this.prototype) {","fNOP.prototype = this.prototype;","}","fBound.prototype = new fNOP();","return fBound;","}","});","");c=function(){return String(this)};L(a,a.M,"toString",c);a.g(a.M,"toString",a.i(c,!1),u);c=function(){return this.valueOf()};L(a,a.M,"valueOf",c);a.g(a.M,"valueOf",a.i(c,!1),u)}
|
||||
function Mb(a,b){function d(e){void 0!==e&&null!==e||J(a,a.m,"Cannot convert '"+e+"' to object")}var c=function(e){if(void 0===e||null===e)return Fc(a)?this:a.s(a.L);if(!(e instanceof C)){var g=a.s(Gc(a,e));g.data=e;return g}return e};a.v=a.i(c,!0);a.g(a.v,"prototype",a.L,u);a.g(a.L,"constructor",a.v,u);a.g(b,"Object",a.v,u);c=function(e){d(e);return Hc(a,Object.getOwnPropertyNames(e instanceof C?e.h:e))};a.g(a.v,"getOwnPropertyNames",a.i(c,!1),u);c=function(e){d(e);e instanceof C&&(e=e.h);return Hc(a,
|
||||
Object.keys(e))};a.g(a.v,"keys",a.i(c,!1),u);c=function(e){if(null===e)return a.s(null);e instanceof C||J(a,a.m,"Object prototype may only be an Object or null");return a.s(e)};a.g(a.v,"create",a.i(c,!1),u);a.$.push("(function() {","var create_ = Object.create;","Object.create = function create(proto, props) {","var obj = create_(proto);","props && Object.defineProperties(obj, props);","return obj;","};","})();","");c=function(e,g,l){g=String(g);e instanceof C||J(a,a.m,"Object.defineProperty called on non-object");
|
||||
l instanceof C||J(a,a.m,"Property description must be an object");!e.h[g]&&e.preventExtensions&&J(a,a.m,"Can't define property '"+g+"', object is not extensible");a.g(e,g,Pa,l.h);return e};a.g(a.v,"defineProperty",a.i(c,!1),u);a.$.push("(function() {","var defineProperty_ = Object.defineProperty;","Object.defineProperty = function defineProperty(obj, prop, d1) {","var d2 = {};","if ('configurable' in d1) d2.configurable = d1.configurable;","if ('enumerable' in d1) d2.enumerable = d1.enumerable;",
|
||||
"if ('writable' in d1) d2.writable = d1.writable;","if ('value' in d1) d2.value = d1.value;","if ('get' in d1) d2.get = d1.get;","if ('set' in d1) d2.set = d1.set;","return defineProperty_(obj, prop, d2);","};","})();","Object.defineProperty(Object, 'defineProperties',","{configurable: true, writable: true, value:","function defineProperties(obj, props) {","var keys = Object.keys(props);","for (var i = 0; i < keys.length; i++) {","Object.defineProperty(obj, keys[i], props[keys[i]]);","}","return obj;",
|
||||
"}","});","");c=function(e,g){e instanceof C||J(a,a.m,"Object.getOwnPropertyDescriptor called on non-object");g=String(g);if(g in e.h){var l=Object.getOwnPropertyDescriptor(e.h,g),v=e.T[g];e=e.W[g];g=a.s(a.L);v||e?(a.g(g,"get",v),a.g(g,"set",e)):(a.g(g,"value",l.value),a.g(g,"writable",l.writable));a.g(g,"configurable",l.configurable);a.g(g,"enumerable",l.enumerable);return g}};a.g(a.v,"getOwnPropertyDescriptor",a.i(c,!1),u);c=function(e){d(e);return Gc(a,e)};a.g(a.v,"getPrototypeOf",a.i(c,!1),u);
|
||||
c=function(e){return!!e&&!e.preventExtensions};a.g(a.v,"isExtensible",a.i(c,!1),u);c=function(e){e instanceof C&&(e.preventExtensions=!0);return e};a.g(a.v,"preventExtensions",a.i(c,!1),u);L(a,a.v,"toString",C.prototype.toString);L(a,a.v,"toLocaleString",C.prototype.toString);L(a,a.v,"valueOf",C.prototype.valueOf);c=function(e){d(this);return this instanceof C?String(e)in this.h:this.hasOwnProperty(e)};L(a,a.v,"hasOwnProperty",c);c=function(e){d(this);return this instanceof C?Object.prototype.propertyIsEnumerable.call(this.h,
|
||||
e):this.propertyIsEnumerable(e)};L(a,a.v,"propertyIsEnumerable",c);c=function(e){for(;;){e=Gc(a,e);if(!e)return!1;if(e===this)return!0}};L(a,a.v,"isPrototypeOf",c)}
|
||||
function Nb(a,b){var d=function(c){var e=Fc(a)?this:Ic(a),g=arguments[0];if(1===arguments.length&&"number"===typeof g)isNaN(Hb(g))&&J(a,a.ib,"Invalid array length"),e.h.length=g;else{for(g=0;g<arguments.length;g++)e.h[g]=arguments[g];e.h.length=g}return e};a.ia=a.i(d,!0);a.Ea=a.ia.h.prototype;a.g(b,"Array",a.ia,u);d=function(c){return c&&"Array"===c.H};a.g(a.ia,"isArray",a.i(d,!1),u);a.g(a.Ea,"length",0,{configurable:!1,enumerable:!1,writable:!0});a.Ea.H="Array";a.$.push("Object.defineProperty(Array.prototype, 'pop',",
|
||||
"{configurable: true, writable: true, value:","function pop() {","if (!this) throw TypeError();","var o = Object(this);","var len = o.length >>> 0;","if (!len || len < 0) {","o.length = 0;","return undefined;","}","len--;","var x = o[len];","delete o[len];","o.length = len;","return x;","}","});","Object.defineProperty(Array.prototype, 'push',","{configurable: true, writable: true, value:","function push(var_args) {","if (!this) throw TypeError();","var o = Object(this);","var len = o.length >>> 0;",
|
||||
"for (var i = 0; i < arguments.length; i++) {","o[len] = arguments[i];","len++;","}","o.length = len;","return len;","}","});","Object.defineProperty(Array.prototype, 'shift',","{configurable: true, writable: true, value:","function shift() {","if (!this) throw TypeError();","var o = Object(this);","var len = o.length >>> 0;","if (!len || len < 0) {","o.length = 0;","return undefined;","}","var value = o[0];","for (var i = 0; i < len - 1; i++) {","if ((i + 1) in o) {","o[i] = o[i + 1];","} else {",
|
||||
"delete o[i];","}","}","delete o[i];","o.length = len - 1;","return value;","}","});","Object.defineProperty(Array.prototype, 'unshift',","{configurable: true, writable: true, value:","function unshift(var_args) {","if (!this) throw TypeError();","var o = Object(this);","var len = o.length >>> 0;","if (!len || len < 0) {","len = 0;","}","for (var i = len - 1; i >= 0; i--) {","if (i in o) {","o[i + arguments.length] = o[i];","} else {","delete o[i + arguments.length];","}","}","for (var i = 0; i < arguments.length; i++) {",
|
||||
"o[i] = arguments[i];","}","return (o.length = len + arguments.length);","}","});","Object.defineProperty(Array.prototype, 'reverse',","{configurable: true, writable: true, value:","function reverse() {","if (!this) throw TypeError();","var o = Object(this);","var len = o.length >>> 0;","if (!len || len < 2) {","return o;","}","for (var i = 0; i < len / 2 - 0.5; i++) {","var x = o[i];","var hasX = i in o;","if ((len - i - 1) in o) {","o[i] = o[len - i - 1];","} else {","delete o[i];","}","if (hasX) {",
|
||||
"o[len - i - 1] = x;","} else {","delete o[len - i - 1];","}","}","return o;","}","});","Object.defineProperty(Array.prototype, 'indexOf',","{configurable: true, writable: true, value:","function indexOf(searchElement, fromIndex) {","if (!this) throw TypeError();","var o = Object(this);","var len = o.length >>> 0;","var n = fromIndex | 0;","if (!len || n >= len) {","return -1;","}","var i = Math.max(n >= 0 ? n : len - Math.abs(n), 0);","while (i < len) {","if (i in o && o[i] === searchElement) {",
|
||||
"return i;","}","i++;","}","return -1;","}","});","Object.defineProperty(Array.prototype, 'lastIndexOf',","{configurable: true, writable: true, value:","function lastIndexOf(searchElement, fromIndex) {","if (!this) throw TypeError();","var o = Object(this);","var len = o.length >>> 0;","if (!len) {","return -1;","}","var n = len - 1;","if (arguments.length > 1) {","n = fromIndex | 0;","if (n) {","n = (n > 0 || -1) * Math.floor(Math.abs(n));","}","}","var i = n >= 0 ? Math.min(n, len - 1) : len - Math.abs(n);",
|
||||
"while (i >= 0) {","if (i in o && o[i] === searchElement) {","return i;","}","i--;","}","return -1;","}","});","Object.defineProperty(Array.prototype, 'slice',","{configurable: true, writable: true, value:","function slice(start, end) {","if (!this) throw TypeError();","var o = Object(this);","var len = o.length >>> 0;","start |= 0;","start = (start >= 0) ? start : Math.max(0, len + start);","if (typeof end !== 'undefined') {","if (end !== Infinity) {","end |= 0;","}","if (end < 0) {","end = len + end;",
|
||||
"} else {","end = Math.min(end, len);","}","} else {","end = len;","}","var size = end - start;","var cloned = new Array(size);","for (var i = 0; i < size; i++) {","if ((start + i) in o) {","cloned[i] = o[start + i];","}","}","return cloned;","}","});","Object.defineProperty(Array.prototype, 'splice',","{configurable: true, writable: true, value:","function splice(start, deleteCount, var_args) {","if (!this) throw TypeError();","var o = Object(this);","var len = o.length >>> 0;","start |= 0;","if (start < 0) {",
|
||||
"start = Math.max(len + start, 0);","} else {","start = Math.min(start, len);","}","if (arguments.length < 1) {","deleteCount = len - start;","} else {","deleteCount |= 0;","deleteCount = Math.max(0, Math.min(deleteCount, len - start));","}","var removed = [];","for (var i = start; i < start + deleteCount; i++) {","if (i in o) {","removed.push(o[i]);","} else {","removed.length++;","}","if ((i + deleteCount) in o) {","o[i] = o[i + deleteCount];","} else {","delete o[i];","}","}","for (var i = start + deleteCount; i < len - deleteCount; i++) {",
|
||||
"if ((i + deleteCount) in o) {","o[i] = o[i + deleteCount];","} else {","delete o[i];","}","}","for (var i = len - deleteCount; i < len; i++) {","delete o[i];","}","len -= deleteCount;","var arl = arguments.length - 2;","for (var i = len - 1; i >= start; i--) {","if (i in o) {","o[i + arl] = o[i];","} else {","delete o[i + arl];","}","}","len += arl;","for (var i = 2; i < arguments.length; i++) {","o[start + i - 2] = arguments[i];","}","o.length = len;","return removed;","}","});","Object.defineProperty(Array.prototype, 'concat',",
|
||||
"{configurable: true, writable: true, value:","function concat(var_args) {","if (!this) throw TypeError();","var o = Object(this);","var cloned = [];","for (var i = -1; i < arguments.length; i++) {","var value = (i === -1) ? o : arguments[i];","if (Array.isArray(value)) {","for (var j = 0, l = value.length; j < l; j++) {","if (j in value) {","cloned.push(value[j]);","} else {","cloned.length++;","}","}","} else {","cloned.push(value);","}","}","return cloned;","}","});","Object.defineProperty(Array.prototype, 'join',",
|
||||
"{configurable: true, writable: true, value:","function join(opt_separator) {","if (!this) throw TypeError();","var o = Object(this);","var sep = typeof opt_separator === 'undefined' ?","',' : ('' + opt_separator);","var str = '';","for (var i = 0; i < o.length; i++) {","if (i && sep) {","str += sep;","}","str += (o[i] === null || o[i] === undefined) ? '' : o[i];","}","return str;","}","});","Object.defineProperty(Array.prototype, 'every',","{configurable: true, writable: true, value:","function every(callbackfn, thisArg) {",
|
||||
"if (!this || typeof callbackfn !== 'function') throw TypeError();","var t, k;","var o = Object(this);","var len = o.length >>> 0;","if (arguments.length > 1) t = thisArg;","k = 0;","while (k < len) {","if (k in o && !callbackfn.call(t, o[k], k, o)) return false;","k++;","}","return true;","}","});","Object.defineProperty(Array.prototype, 'filter',","{configurable: true, writable: true, value:","function filter(fun, var_args) {","if (this === void 0 || this === null || typeof fun !== 'function') throw TypeError();",
|
||||
"var o = Object(this);","var len = o.length >>> 0;","var res = [];","var thisArg = arguments.length >= 2 ? arguments[1] : void 0;","for (var i = 0; i < len; i++) {","if (i in o) {","var val = o[i];","if (fun.call(thisArg, val, i, o)) res.push(val);","}","}","return res;","}","});","Object.defineProperty(Array.prototype, 'forEach',","{configurable: true, writable: true, value:","function forEach(callback, thisArg) {","if (!this || typeof callback !== 'function') throw TypeError();","var t, k;","var o = Object(this);",
|
||||
"var len = o.length >>> 0;","if (arguments.length > 1) t = thisArg;","k = 0;","while (k < len) {","if (k in o) callback.call(t, o[k], k, o);","k++;","}","}","});","Object.defineProperty(Array.prototype, 'map',","{configurable: true, writable: true, value:","function map(callback, thisArg) {","if (!this || typeof callback !== 'function') throw TypeError();","var t, a, k;","var o = Object(this);","var len = o.length >>> 0;","if (arguments.length > 1) t = thisArg;","a = new Array(len);","k = 0;","while (k < len) {",
|
||||
"if (k in o) a[k] = callback.call(t, o[k], k, o);","k++;","}","return a;","}","});","Object.defineProperty(Array.prototype, 'reduce',","{configurable: true, writable: true, value:","function reduce(callback /*, initialValue*/) {","if (!this || typeof callback !== 'function') throw TypeError();","var o = Object(this), len = o.length >>> 0, k = 0, value;","if (arguments.length === 2) {","value = arguments[1];","} else {","while (k < len && !(k in o)) k++;","if (k >= len) {","throw TypeError('Reduce of empty array with no initial value');",
|
||||
"}","value = o[k++];","}","for (; k < len; k++) {","if (k in o) value = callback(value, o[k], k, o);","}","return value;","}","});","Object.defineProperty(Array.prototype, 'reduceRight',","{configurable: true, writable: true, value:","function reduceRight(callback /*, initialValue*/) {","if (null === this || 'undefined' === typeof this || 'function' !== typeof callback) throw TypeError();","var o = Object(this), len = o.length >>> 0, k = len - 1, value;","if (arguments.length >= 2) {","value = arguments[1];",
|
||||
"} else {","while (k >= 0 && !(k in o)) k--;","if (k < 0) {","throw TypeError('Reduce of empty array with no initial value');","}","value = o[k--];","}","for (; k >= 0; k--) {","if (k in o) value = callback(value, o[k], k, o);","}","return value;","}","});","Object.defineProperty(Array.prototype, 'some',","{configurable: true, writable: true, value:","function some(fun/*, thisArg*/) {","if (!this || typeof fun !== 'function') throw TypeError();","var o = Object(this);","var len = o.length >>> 0;",
|
||||
"var thisArg = arguments.length >= 2 ? arguments[1] : void 0;","for (var i = 0; i < len; i++) {","if (i in o && fun.call(thisArg, o[i], i, o)) {","return true;","}","}","return false;","}","});","Object.defineProperty(Array.prototype, 'sort',","{configurable: true, writable: true, value:","function sort(opt_comp) {","if (!this) throw TypeError();","if (typeof opt_comp !== 'function') {","opt_comp = undefined;","}","for (var i = 0; i < this.length; i++) {","var changes = 0;","for (var j = 0; j < this.length - i - 1; j++) {",
|
||||
"if (opt_comp ? (opt_comp(this[j], this[j + 1]) > 0) :","(String(this[j]) > String(this[j + 1]))) {","var swap = this[j];","var hasSwap = j in this;","if ((j + 1) in this) {","this[j] = this[j + 1];","} else {","delete this[j];","}","if (hasSwap) {","this[j + 1] = swap;","} else {","delete this[j + 1];","}","changes++;","}","}","if (!changes) break;","}","return this;","}","});","Object.defineProperty(Array.prototype, 'toLocaleString',","{configurable: true, writable: true, value:","function toLocaleString() {",
|
||||
"if (!this) throw TypeError();","var o = Object(this);","var out = [];","for (var i = 0; i < o.length; i++) {","out[i] = (o[i] === null || o[i] === undefined) ? '' : o[i].toLocaleString();","}","return out.join(',');","}","});","")}
|
||||
function Ob(a,b){var d=function(c){c=arguments.length?gb.String(c):"";return Fc(a)?(this.data=c,this):c};a.J=a.i(d,!0);a.g(b,"String",a.J,u);a.g(a.J,"fromCharCode",a.i(String.fromCharCode,!1),u);b="charAt charCodeAt concat indexOf lastIndexOf slice substr substring toLocaleLowerCase toLocaleUpperCase toLowerCase toUpperCase trim".split(" ");for(d=0;d<b.length;d++)L(a,a.J,b[d],String.prototype[b[d]]);d=function(c,e,g){e=a.O(e);g=a.O(g);try{return String(this).localeCompare(c,e,g)}catch(l){J(a,a.F,
|
||||
"localeCompare: "+l.message)}};L(a,a.J,"localeCompare",d);d=function(c,e,g){var l=String(this);e=e?Number(e):void 0;if(P(a,c,a.I)&&(c=c.data,Jc(a,c,g),2===a.REGEXP_MODE)){if(fb)c=Kc(a,"string.split(separator, limit)",{string:l,separator:c,limit:e},c,g),c!==Qa&&g(Hc(a,c));else{var v=a.da(),E=Lc(a,c,v,g);v.onmessage=function(M){clearTimeout(E);g(Hc(a,M.data))};v.postMessage(["split",l,c,e])}return}c=l.split(c,e);g(Hc(a,c))};Mc(a,a.J,"split",d);d=function(c,e){var g=String(this);P(a,c,a.I)?c=c.data:
|
||||
c=new RegExp(c);Jc(a,c,e);if(2===a.REGEXP_MODE)if(fb)c=Kc(a,"string.match(regexp)",{string:g,regexp:c},c,e),c!==Qa&&e(c&&Hc(a,c));else{var l=a.da(),v=Lc(a,c,l,e);l.onmessage=function(E){clearTimeout(v);e(E.data&&Hc(a,E.data))};l.postMessage(["match",g,c])}else c=g.match(c),e(c&&Hc(a,c))};Mc(a,a.J,"match",d);d=function(c,e){var g=String(this);P(a,c,a.I)?c=c.data:c=new RegExp(c);Jc(a,c,e);if(2===a.REGEXP_MODE)if(fb)c=Kc(a,"string.search(regexp)",{string:g,regexp:c},c,e),c!==Qa&&e(c);else{var l=a.da(),
|
||||
v=Lc(a,c,l,e);l.onmessage=function(E){clearTimeout(v);e(E.data)};l.postMessage(["search",g,c])}else e(g.search(c))};Mc(a,a.J,"search",d);d=function(c,e,g){var l=String(this);e=String(e);if(P(a,c,a.I)&&(c=c.data,Jc(a,c,g),2===a.REGEXP_MODE)){if(fb)c=Kc(a,"string.replace(substr, newSubstr)",{string:l,substr:c,newSubstr:e},c,g),c!==Qa&&g(c);else{var v=a.da(),E=Lc(a,c,v,g);v.onmessage=function(M){clearTimeout(E);g(M.data)};v.postMessage(["replace",l,c,e])}return}g(l.replace(c,e))};Mc(a,a.J,"replace",
|
||||
d);a.$.push("(function() {","var replace_ = String.prototype.replace;","String.prototype.replace = function replace(substr, newSubstr) {","if (typeof newSubstr !== 'function') {","return replace_.call(this, substr, newSubstr);","}","var str = this;","if (substr instanceof RegExp) {","var subs = [];","var m = substr.exec(str);","while (m) {","m.push(m.index, str);","var inject = newSubstr.apply(null, m);","subs.push([m.index, m[0].length, inject]);","m = substr.global ? substr.exec(str) : null;","}",
|
||||
"for (var i = subs.length - 1; i >= 0; i--) {","str = str.substring(0, subs[i][0]) + subs[i][2] + str.substring(subs[i][0] + subs[i][1]);","}","} else {","var i = str.indexOf(substr);","if (i !== -1) {","var inject = newSubstr(str.substr(i, substr.length), i, str);","str = str.substring(0, i) + inject + str.substring(i + substr.length);","}","}","return str;","};","})();","")}function Pb(a,b){a.gb=a.i(function(d){d=gb.Boolean(d);return Fc(a)?(this.data=d,this):d},!0);a.g(b,"Boolean",a.gb,u)}
|
||||
function Qb(a,b){var d=function(c){c=arguments.length?gb.Number(c):0;return Fc(a)?(this.data=c,this):c};a.Z=a.i(d,!0);a.g(b,"Number",a.Z,u);b=["MAX_VALUE","MIN_VALUE","NaN","NEGATIVE_INFINITY","POSITIVE_INFINITY"];for(d=0;d<b.length;d++)a.g(a.Z,b[d],Number[b[d]],La);d=function(c){try{return Number(this).toExponential(c)}catch(e){J(a,a.F,e.message)}};L(a,a.Z,"toExponential",d);d=function(c){try{return Number(this).toFixed(c)}catch(e){J(a,a.F,e.message)}};L(a,a.Z,"toFixed",d);d=function(c){try{return Number(this).toPrecision(c)}catch(e){J(a,
|
||||
a.F,e.message)}};L(a,a.Z,"toPrecision",d);d=function(c){try{return Number(this).toString(c)}catch(e){J(a,a.F,e.message)}};L(a,a.Z,"toString",d);d=function(c,e){c=c?a.O(c):void 0;e=e?a.O(e):void 0;return Number(this).toLocaleString(c,e)};L(a,a.Z,"toLocaleString",d)}
|
||||
function Rb(a,b){var d=function(e,g){if(!Fc(a))return gb.Date();var l=[null].concat(Array.from(arguments));this.data=new (Function.prototype.bind.apply(gb.Date,l));return this};a.Y=a.i(d,!0);a.hb=a.Y.h.prototype;a.g(b,"Date",a.Y,u);a.g(a.Y,"now",a.i(Date.now,!1),u);a.g(a.Y,"parse",a.i(Date.parse,!1),u);a.g(a.Y,"UTC",a.i(Date.UTC,!1),u);b="getDate getDay getFullYear getHours getMilliseconds getMinutes getMonth getSeconds getTime getTimezoneOffset getUTCDate getUTCDay getUTCFullYear getUTCHours getUTCMilliseconds getUTCMinutes getUTCMonth getUTCSeconds getYear setDate setFullYear setHours setMilliseconds setMinutes setMonth setSeconds setTime setUTCDate setUTCFullYear setUTCHours setUTCMilliseconds setUTCMinutes setUTCMonth setUTCSeconds setYear toDateString toISOString toJSON toGMTString toLocaleDateString toLocaleString toLocaleTimeString toTimeString toUTCString".split(" ");
|
||||
for(var c=0;c<b.length;c++)d=function(e){return function(g){var l=this.data;l instanceof Date||J(a,a.m,e+" not called on a Date");for(var v=[],E=0;E<arguments.length;E++)v[E]=a.O(arguments[E]);return l[e].apply(l,v)}}(b[c]),L(a,a.Y,b[c],d)}
|
||||
function Sb(a,b){var d=function(c,e){if(Fc(a))var g=this;else{if(void 0===e&&P(a,c,a.I))return c;g=a.s(a.Fa)}c=void 0===c?"":String(c);e=e?String(e):"";Nc(a,g,new gb.RegExp(c,e));return g};a.I=a.i(d,!0);a.Fa=a.I.h.prototype;a.g(b,"RegExp",a.I,u);a.g(a.I.h.prototype,"global",void 0,B);a.g(a.I.h.prototype,"ignoreCase",void 0,B);a.g(a.I.h.prototype,"multiline",void 0,B);a.g(a.I.h.prototype,"source","(?:)",B);a.$.push("Object.defineProperty(RegExp.prototype, 'test',","{configurable: true, writable: true, value:",
|
||||
"function test(str) {","return !!this.exec(str);","}","});");d=function(c,e){function g(D){if(D){var ta=Hc(a,D);a.g(ta,"index",D.index);a.g(ta,"input",D.input);return ta}return null}var l=this.data;c=String(c);l.lastIndex=Number(a.D(this,"lastIndex"));Jc(a,l,e);if(2===a.REGEXP_MODE)if(fb)c=Kc(a,"regexp.exec(string)",{string:c,regexp:l},l,e),c!==Qa&&(a.g(this,"lastIndex",l.lastIndex),e(g(c)));else{var v=a.da(),E=Lc(a,l,v,e),M=this;v.onmessage=function(D){clearTimeout(E);a.g(M,"lastIndex",D.data[1]);
|
||||
e(g(D.data[0]))};v.postMessage(["exec",l,l.lastIndex,c])}else c=l.exec(c),a.g(this,"lastIndex",l.lastIndex),e(g(c))};Mc(a,a.I,"exec",d)}
|
||||
function Tb(a,b){function d(c){var e=a.i(function(g){var l=Fc(a)?this:a.ta(e);Oc(a,l,g);return l},!0);a.g(e,"prototype",a.ta(a.F),u);a.g(e.h.prototype,"name",c,u);a.g(b,c,e,u);return e}a.F=a.i(function(c){var e=Fc(a)?this:a.ta(a.F);Oc(a,e,c);return e},!0);a.g(b,"Error",a.F,u);a.g(a.F.h.prototype,"message","",u);a.g(a.F.h.prototype,"name","Error",u);d("EvalError");a.ib=d("RangeError");a.jb=d("ReferenceError");a.ja=d("SyntaxError");a.m=d("TypeError");a.zb=d("URIError")}
|
||||
function Ub(a,b){var d=a.s(a.L);a.g(b,"Math",d,u);var c="E LN2 LN10 LOG2E LOG10E PI SQRT1_2 SQRT2".split(" ");for(b=0;b<c.length;b++)a.g(d,c[b],Math[c[b]],B);c="abs acos asin atan atan2 ceil cos exp floor log max min pow random round sin sqrt tan".split(" ");for(b=0;b<c.length;b++)a.g(d,c[b],a.i(Math[c[b]],!1),u)}
|
||||
function Cc(a,b){function d(e){try{var g=JSON.parse(String(e))}catch(l){J(a,a.ja,l.message)}return a.Ba(g)}var c=a.s(a.L);a.g(b,"JSON",c,u);a.g(c,"parse",a.i(d,!1));d=function(e,g,l){g&&"Function"===g.H?J(a,a.m,"Function replacer on JSON.stringify not supported"):g&&"Array"===g.H?(g=Ec(a,g),g=g.filter(function(E){return"string"===typeof E||"number"===typeof E})):g=null;"string"!==typeof l&&"number"!==typeof l&&(l=void 0);e=a.O(e);try{var v=JSON.stringify(e,g,l)}catch(E){J(a,a.m,E.message)}return v};
|
||||
a.g(c,"stringify",a.i(d,!1))}function P(a,b,d){if(null===b||void 0===b||!d)return!1;d=d.h.prototype;if(b===d)return!0;for(b=Gc(a,b);b;){if(b===d)return!0;b=b.ra}return!1}function Nc(a,b,d){b.data=new RegExp(d.source,d.flags);a.g(b,"lastIndex",d.lastIndex,u);a.g(b,"source",d.source,B);a.g(b,"global",d.global,B);a.g(b,"ignoreCase",d.ignoreCase,B);a.g(b,"multiline",d.multiline,B)}
|
||||
function Oc(a,b,d){d&&a.g(b,"message",String(d),u);d=[];for(var c=a.o.length-1;0<=c;c--){var e=a.o[c],g=e.node;"CallExpression"===g.type&&(e=e.ba)&&d.length&&(d[d.length-1].name=a.D(e,"name"));!g.loc||d.length&&"CallExpression"!==g.type||d.push({V:g.loc})}g=String(a.D(b,"name"));c=String(a.D(b,"message"));e=g+": "+c+"\n";for(c=0;c<d.length;c++){var l=d[c].V;g=d[c].name;l=l.source+":"+l.start.line+":"+l.start.column;e=g?e+(" at "+g+" ("+l+")\n"):e+(" at "+l+"\n")}a.g(b,"stack",e.trim(),u)}
|
||||
p.da=function(){var a=this.da.Db;a||(a=new Blob([Gb.join("\n")],{type:"application/javascript"}),this.da.Db=a);return new Worker(URL.createObjectURL(a))};function Kc(a,b,d,c,e){var g={timeout:a.REGEXP_THREAD_TIMEOUT};try{return fb.runInNewContext(b,d,g)}catch(l){e(null),J(a,a.F,"RegExp Timeout: "+c)}return Qa}
|
||||
function Jc(a,b,d){if(0===a.REGEXP_MODE)var c=!1;else if(1===a.REGEXP_MODE)c=!0;else if(fb)c=!0;else if("function"===typeof Worker&&"function"===typeof URL)c=!0;else if("function"===typeof require){try{fb=require("vm")}catch(e){}c=!!fb}else c=!1;c||(d(null),J(a,a.F,"Regular expressions not supported: "+b))}function Lc(a,b,d,c){return setTimeout(function(){d.terminate();c(null);try{J(a,a.F,"RegExp Timeout: "+b)}catch(e){}},a.REGEXP_THREAD_TIMEOUT)}p.ta=function(a){return this.s(a&&a.h.prototype)};
|
||||
p.s=function(a){if("object"!==typeof a)throw Error("Non object prototype");a=new C(a);P(this,a,this.F)&&(a.H="Error");return a};function Ic(a){var b=a.s(a.Ea);a.g(b,"length",0,{configurable:!1,enumerable:!1,writable:!0});b.H="Array";return b}function ed(a,b,d){var c=a.s(a.X);d?(d=a.s(a.L),a.g(c,"prototype",d,u),a.g(d,"constructor",c,u)):c.ub=!0;a.g(c,"length",b,B);c.H="Function";return c}
|
||||
function Dc(a,b,d,c){var e=ed(a,b.params.length,!0);e.Oa=d;e.node=b;a.g(e,"name",b.id?String(b.id.name):c||"",B);return e}p.i=function(a,b){b=ed(this,a.length,b);b.La=a;a.id=this.Ra++;this.g(b,"name",a.name,B);return b};p.ob=function(a){var b=ed(this,a.length,!0);b.Ta=a;a.id=this.Ra++;this.g(b,"name",a.name,B);return b};
|
||||
p.Ba=function(a){if(a instanceof C)throw Error("Object is already pseudo");if("object"!==typeof a&&"function"!==typeof a||null===a)return a;if(a instanceof RegExp){var b=this.s(this.Fa);Nc(this,b,a);return b}if(a instanceof Date)return b=this.s(this.hb),b.data=new Date(a.valueOf()),b;if("function"===typeof a){var d=this;b=Object.getOwnPropertyDescriptor(a,"prototype");return this.i(function(){var e=Array.prototype.slice.call(arguments).map(function(g){return d.O(g)});e=a.apply(d,e);return d.Ba(e)},
|
||||
!!b)}if(Array.isArray(a)){b=Ic(this);for(var c=0;c<a.length;c++)c in a&&this.g(b,c,this.Ba(a[c]));return b}b=this.s(this.L);for(c in a)this.g(b,c,this.Ba(a[c]));return b};
|
||||
p.O=function(a,b){if("object"!==typeof a&&"function"!==typeof a||null===a)return a;if(!(a instanceof C))throw Error("Object is not pseudo");if(P(this,a,this.I))return b=new RegExp(a.data.source,a.data.flags),b.lastIndex=a.data.lastIndex,b;if(P(this,a,this.Y))return new Date(a.data.valueOf());b=b||{bb:[],Ka:[]};var d=b.bb.indexOf(a);if(-1!==d)return b.Ka[d];b.bb.push(a);if(P(this,a,this.ia)){var c=[];b.Ka.push(c);var e=this.D(a,"length");for(d=0;d<e;d++)fd(this,a,d)&&(c[d]=this.O(this.D(a,d),b))}else for(e in c=
|
||||
{},b.Ka.push(c),a.h)d=this.O(a.h[e],b),Object.defineProperty(c,e,{value:d,writable:!0,enumerable:!0,configurable:!0});b.bb.pop();b.Ka.pop();return c};function Hc(a,b){for(var d=Ic(a),c=Object.getOwnPropertyNames(b),e=0;e<c.length;e++)a.g(d,c[e],b[c[e]]);return d}function Ec(a,b){var d=[],c;for(c in b.h)d[c]=a.D(b,c);d.length=Hb(a.D(b,"length"))||0;return d}
|
||||
function Gc(a,b){switch(typeof b){case "number":return a.Z.h.prototype;case "boolean":return a.gb.h.prototype;case "string":return a.J.h.prototype}return b?b.ra:null}
|
||||
p.D=function(a,b){if(this.N)throw Error("Getter not supported in that context");b=String(b);void 0!==a&&null!==a||J(this,this.m,"Cannot read property '"+b+"' of "+a);if("object"===typeof a&&!(a instanceof C))throw TypeError("Expecting native value or pseudo object");if("length"===b){if(P(this,a,this.J))return String(a).length}else if(64>b.charCodeAt(0)&&P(this,a,this.J)){var d=Ib(b);if(!isNaN(d)&&d<String(a).length)return String(a)[d]}do if(a.h&&b in a.h)return(d=a.T[b])?(this.N=!0,d):a.h[b];while(a=
|
||||
Gc(this,a))};function fd(a,b,d){if(!(b instanceof C))throw TypeError("Primitive data type has no properties");d=String(d);if("length"===d&&P(a,b,a.J))return!0;if(P(a,b,a.J)){var c=Ib(d);if(!isNaN(c)&&c<String(b).length)return!0}do if(b.h&&d in b.h)return!0;while(b=Gc(a,b));return!1}
|
||||
p.g=function(a,b,d,c){if(this.Da)throw Error("Setter not supported in that context");b=String(b);void 0!==a&&null!==a||J(this,this.m,"Cannot set property '"+b+"' of "+a);if("object"===typeof a&&!(a instanceof C))throw TypeError("Expecting native value or pseudo object");c&&("get"in c||"set"in c)&&("value"in c||"writable"in c)&&J(this,this.m,"Invalid property descriptor. Cannot both specify accessors and a value or writable attribute");var e=!this.o||gd(this).P;if(a instanceof C){if(P(this,a,this.J)){var g=
|
||||
Ib(b);if("length"===b||!isNaN(g)&&g<String(a).length){e&&J(this,this.m,"Cannot assign to read only property '"+b+"' of String '"+a.data+"'");return}}if("Array"===a.H)if(g=a.h.length,"length"===b){if(c){if(!("value"in c))return;d=c.value}d=Hb(d);isNaN(d)&&J(this,this.ib,"Invalid array length");if(d<g)for(l in a.h){var l=Ib(l);!isNaN(l)&&d<=l&&delete a.h[l]}}else isNaN(l=Ib(b))||(a.h.length=Math.max(g,l+1));if(!a.preventExtensions||b in a.h)if(c){e={};"get"in c&&c.get&&(a.T[b]=c.get,e.get=this.g.Vb);
|
||||
"set"in c&&c.set&&(a.W[b]=c.set,e.set=this.g.Wb);"configurable"in c&&(e.configurable=c.configurable);"enumerable"in c&&(e.enumerable=c.enumerable);"writable"in c&&(e.writable=c.writable,delete a.T[b],delete a.W[b]);"value"in c?(e.value=c.value,delete a.T[b],delete a.W[b]):d!==Pa&&(e.value=d,delete a.T[b],delete a.W[b]);try{Object.defineProperty(a.h,b,e)}catch(v){J(this,this.m,"Cannot redefine property: "+b)}"get"in c&&!c.get&&delete a.T[b];"set"in c&&!c.set&&delete a.W[b]}else{if(d===Pa)throw ReferenceError("Value not specified.");
|
||||
for(c=a;!(b in c.h);)if(c=Gc(this,c),!c){c=a;break}if(c.W&&c.W[b])return this.Da=!0,c.W[b];if(c.T&&c.T[b])e&&J(this,this.m,"Cannot set property '"+b+"' of object '"+a+"' which only has a getter");else try{a.h[b]=d}catch(v){e&&J(this,this.m,"Cannot assign to read only property '"+b+"' of object '"+a+"'")}}else e&&J(this,this.m,"Can't add property '"+b+"', object is not extensible")}else e&&J(this,this.m,"Can't create property '"+b+"' on '"+a+"'")};
|
||||
p.g.Vb=function(){throw Error("Placeholder getter");};p.g.Wb=function(){throw Error("Placeholder setter");};function L(a,b,d,c){a.g(b.h.prototype,d,a.i(c,!1),u)}function Mc(a,b,d,c){a.g(b.h.prototype,d,a.ob(c),u)}function gd(a){a=a.o[a.o.length-1].scope;if(!a)throw Error("No scope found.");return a}
|
||||
function Ha(a,b,d){var c=!1;if(d&&d.P)c=!0;else{var e=b.body&&b.body[0];e&&e.xa&&"Literal"===e.xa.type&&"use strict"===e.xa.value&&(c=!0)}e=a.s(null);c=new hd(d,c,e);d||Kb(a,c.object);Jb(a,b,c);return c}function id(a,b,d){if(!b)throw Error("parentScope required");a=d||a.s(null);return new hd(b,b.P,a)}
|
||||
function jd(a,b){for(var d=gd(a);d&&d!==a.R;){if(b in d.object.h)return d.object.h[b];d=d.Oa}if(d===a.R&&fd(a,d.object,b))return a.D(d.object,b);d=a.o[a.o.length-1].node;"UnaryExpression"===d.type&&"typeof"===d.operator||J(a,a.jb,b+" is not defined")}function kd(a,b,d){for(var c=gd(a),e=c.P;c&&c!==a.R;){if(b in c.object.h){c.object.h[b]=d;return}c=c.Oa}if(c===a.R&&(!e||fd(a,c.object,b)))return a.g(c.object,b,d);J(a,a.jb,b+" is not defined")}
|
||||
function Jb(a,b,d){if("VariableDeclaration"===b.type)for(var c=0;c<b.declarations.length;c++)a.g(d.object,b.declarations[c].id.name,void 0,Ma);else{if("FunctionDeclaration"===b.type){a.g(d.object,b.id.name,Dc(a,b,d),Ma);return}if("FunctionExpression"===b.type||"ExpressionStatement"===b.type)return}var e=b.constructor,g;for(g in b){var l=b[g];if(l&&"object"===typeof l)if(Array.isArray(l))for(c=0;c<l.length;c++)l[c]&&l[c].constructor===e&&Jb(a,l[c],d);else l.constructor===e&&Jb(a,l,d)}}
|
||||
function Fc(a){return a.o[a.o.length-1].isConstructor}function ld(a,b){return b[0]===Oa?jd(a,b[1]):a.D(b[0],b[1])}function md(a,b,d){return b[0]===Oa?kd(a,b[1],d):a.g(b[0],b[1],d)}function J(a,b,d){void 0!==d&&(b=a.ta(b),Oc(a,b,d));nd(a,4,b,void 0);throw Na;}
|
||||
function nd(a,b,d,c){if(0===b)throw TypeError("Should not unwind for NORMAL completions");var e=a.o;a:for(;0<e.length;e.pop()){var g=e[e.length-1];switch(g.node.type){case "TryStatement":g.aa={type:b,value:d,label:c};return;case "CallExpression":case "NewExpression":if(3===b){g.value=d;return}if(4!==b)throw Error("Unsynatctic break/continue not rejected by Acorn");break;case "Program":g.done=!0;break a}if(1===b){if(c?g.labels&&-1!==g.labels.indexOf(c):g.U||g.Tb){e.pop();return}}else if(2===b&&(c?
|
||||
g.labels&&-1!==g.labels.indexOf(c):g.U))return}P(a,d,a.F)?(b={EvalError:EvalError,RangeError:RangeError,ReferenceError:ReferenceError,SyntaxError:SyntaxError,TypeError:TypeError,URIError:URIError},c=String(a.D(d,"name")),e=a.D(d,"message").valueOf(),b=(b[c]||Error)(e),b.stack=String(a.D(d,"stack"))):b=String(d);throw b;}
|
||||
function od(a,b,d){if(!a.N)throw Error("Unexpected call to createGetter");a.N=!1;d=Array.isArray(d)?d[0]:d;var c=new a.Ga({options:{}});c.type="CallExpression";a=new t(c,a.o[a.o.length-1].scope);a.na=!0;a.B=d;a.ba=b;a.Xa=!0;a.G=[];return a}function pd(a,b,d,c){if(!a.Da)throw Error("Unexpected call to createSetter");a.Da=!1;d=Array.isArray(d)?d[0]:a.Sa;var e=new a.Ga({options:{}});e.type="CallExpression";a=new t(e,a.o[a.o.length-1].scope);a.na=!0;a.B=d;a.ba=b;a.Xa=!0;a.G=[c];return a}
|
||||
function qd(a,b){return void 0===b||null===b?a.Sa:b instanceof C?b:(a=a.s(Gc(a,b)),a.data=b,a)}p.Qb=function(){return this.R};p.Rb=function(){return this.o};p.$b=function(a){this.o=a};function t(a,b){this.node=a;this.scope=b}function hd(a,b,d){this.Oa=a;this.P=b;this.object=d}function C(a){this.T=Object.create(null);this.W=Object.create(null);this.h=Object.create(null);this.ra=a}p=C.prototype;p.ra=null;p.H="Object";p.data=null;
|
||||
p.toString=function(){if(!(this instanceof C))return String(this);if("Array"===this.H){var a=eb;a.push(this);try{var b=[],d=this.h.length,c=!1;1024<d&&(d=1E3,c=!0);for(var e=0;e<d;e++){var g=this.h[e];b[e]=g instanceof C&&-1!==a.indexOf(g)?"...":g}c&&b.push("...")}finally{a.pop()}return b.join(",")}if("Error"===this.H){a=eb;if(-1!==a.indexOf(this))return"[object Error]";d=this;do if("name"in d.h){b=d.h.name;break}while(d=d.ra);d=this;do if("message"in d.h){c=d.h.message;break}while(d=d.ra);a.push(this);
|
||||
try{b=b&&String(b),c=c&&String(c)}finally{a.pop()}return c?b+": "+c:String(b)}return null!==this.data?String(this.data):"[object "+this.H+"]"};p.valueOf=function(){return void 0===this.data||null===this.data||this.data instanceof RegExp?this:this.data instanceof Date?this.data.valueOf():this.data};
|
||||
r.prototype.stepArrayExpression=function(a,b,d){d=d.elements;var c=b.A||0;b.Ha?(this.g(b.Ha,c,b.value),c++):(b.Ha=Ic(this),b.Ha.h.length=d.length);for(;c<d.length;){if(d[c])return b.A=c,new t(d[c],b.scope);c++}a.pop();a[a.length-1].value=b.Ha};
|
||||
r.prototype.stepAssignmentExpression=function(a,b,d){if(!b.ea)return b.ea=!0,b=new t(d.left,b.scope),b.ma=!0,b;if(!b.wa){b.ya||(b.ya=b.value);b.ua&&(b.fa=b.value);if(!b.ua&&"="!==d.operator&&(a=ld(this,b.ya),b.fa=a,this.N))return b.ua=!0,od(this,a,b.ya);b.wa=!0;"="===d.operator&&"Identifier"===d.left.type&&(b.Ia=d.left.name);return new t(d.right,b.scope)}if(b.oa)a.pop(),a[a.length-1].value=b.cb;else{var c=b.fa,e=b.value;switch(d.operator){case "=":c=e;break;case "+=":c+=e;break;case "-=":c-=e;break;
|
||||
case "*=":c*=e;break;case "/=":c/=e;break;case "%=":c%=e;break;case "<<=":c<<=e;break;case ">>=":c>>=e;break;case ">>>=":c>>>=e;break;case "&=":c&=e;break;case "^=":c^=e;break;case "|=":c|=e;break;default:throw SyntaxError("Unknown assignment expression: "+d.operator);}if(d=md(this,b.ya,c))return b.oa=!0,b.cb=c,pd(this,d,b.ya,c);a.pop();a[a.length-1].value=c}};
|
||||
r.prototype.stepBinaryExpression=function(a,b,d){if(!b.ea)return b.ea=!0,new t(d.left,b.scope);if(!b.wa)return b.wa=!0,b.fa=b.value,new t(d.right,b.scope);a.pop();var c=b.fa;b=b.value;switch(d.operator){case "==":d=c==b;break;case "!=":d=c!=b;break;case "===":d=c===b;break;case "!==":d=c!==b;break;case ">":d=c>b;break;case ">=":d=c>=b;break;case "<":d=c<b;break;case "<=":d=c<=b;break;case "+":d=c+b;break;case "-":d=c-b;break;case "*":d=c*b;break;case "/":d=c/b;break;case "%":d=c%b;break;case "&":d=
|
||||
c&b;break;case "|":d=c|b;break;case "^":d=c^b;break;case "<<":d=c<<b;break;case ">>":d=c>>b;break;case ">>>":d=c>>>b;break;case "in":b instanceof C||J(this,this.m,"'in' expects an object, not '"+b+"'");d=fd(this,b,c);break;case "instanceof":P(this,b,this.M)||J(this,this.m,"Right-hand side of instanceof is not an object");d=c instanceof C?P(this,c,b):!1;break;default:throw SyntaxError("Unknown binary operator: "+d.operator);}a[a.length-1].value=d};
|
||||
r.prototype.stepBlockStatement=function(a,b,d){var c=b.A||0;if(d=d.body[c])return b.A=c+1,new t(d,b.scope);a.pop()};r.prototype.stepBreakStatement=function(a,b,d){nd(this,1,void 0,d.label&&d.label.name)};r.prototype.Ab=0;
|
||||
r.prototype.stepCallExpression=function(a,b,d){if(!b.na){b.na=1;var c=new t(d.callee,b.scope);c.ma=!0;return c}if(1===b.na){b.na=2;c=b.value;if(Array.isArray(c)){if(b.ba=ld(this,c),c[0]===Oa?b.Gb="eval"===c[1]:b.B=c[0],c=b.ba,this.N)return b.na=1,od(this,c,b.value)}else b.ba=c;b.G=[];b.A=0}c=b.ba;if(!b.Xa){0!==b.A&&b.G.push(b.value);if(d.arguments[b.A])return new t(d.arguments[b.A++],b.scope);if("NewExpression"===d.type){c instanceof C&&!c.ub||J(this,this.m,c+" is not a constructor");if(c===this.ia)b.B=
|
||||
Ic(this);else{var e=c.h.prototype;if("object"!==typeof e||null===e)e=this.L;b.B=this.s(e)}b.isConstructor=!0}b.Xa=!0}if(b.Ya)a.pop(),a[a.length-1].value=b.isConstructor&&"object"!==typeof b.value?b.B:b.value;else{b.Ya=!0;c instanceof C||J(this,this.m,c+" is not a function");if(a=c.node){d=Ha(this,a.body,c.Oa);for(var g=0;g<a.params.length;g++)this.g(d.object,a.params[g].name,b.G.length>g?b.G[g]:void 0);e=Ic(this);for(g=0;g<b.G.length;g++)this.g(e,g,b.G[g]);this.g(d.object,"arguments",e);(g=a.id&&
|
||||
a.id.name)&&this.g(d.object,g,c);d.P||(b.B=qd(this,b.B));this.g(d.object,"this",b.B,Ka);b.value=void 0;return new t(a.body,d)}if(c.eval)if(c=b.G[0],"string"!==typeof c)b.value=c;else{try{g=Ga(String(c),"eval"+this.Ab++)}catch(v){J(this,this.ja,"Invalid code: "+v.message)}c=new this.Ga({options:{}});c.type="EvalProgram_";c.body=g.body;Ia(c,d.start,d.end);d=b.Gb?b.scope:this.R;d.P?d=Ha(this,g,d):Jb(this,g,d);this.value=void 0;return new t(c,d)}else if(c.La)b.scope.P||(b.B=qd(this,b.B)),b.value=c.La.apply(b.B,
|
||||
b.G);else if(c.Ta){var l=this;g=c.Ta.length-1;g=b.G.concat(Array(g)).slice(0,g);g.push(function(v){b.value=v;l.sa=!1});this.sa=!0;b.scope.P||(b.B=qd(this,b.B));c.Ta.apply(b.B,g)}else J(this,this.m,c.H+" is not callable")}};r.prototype.stepCatchClause=function(a,b,d){if(b.S)a.pop();else return b.S=!0,a=id(this,b.scope),this.g(a.object,d.param.name,b.cc),new t(d.body,a)};
|
||||
r.prototype.stepConditionalExpression=function(a,b,d){var c=b.ga||0;if(0===c)return b.ga=1,new t(d.test,b.scope);if(1===c){b.ga=2;if((c=!!b.value)&&d.consequent)return new t(d.consequent,b.scope);if(!c&&d.alternate)return new t(d.alternate,b.scope);this.value=void 0}a.pop();"ConditionalExpression"===d.type&&(a[a.length-1].value=b.value)};r.prototype.stepContinueStatement=function(a,b,d){nd(this,2,void 0,d.label&&d.label.name)};r.prototype.stepDebuggerStatement=function(a){a.pop()};
|
||||
r.prototype.stepDoWhileStatement=function(a,b,d){"DoWhileStatement"===d.type&&void 0===b.ca&&(b.value=!0,b.ca=!0);if(!b.ca)return b.ca=!0,new t(d.test,b.scope);if(!b.value)a.pop();else if(d.body)return b.ca=!1,b.U=!0,new t(d.body,b.scope)};r.prototype.stepEmptyStatement=function(a){a.pop()};r.prototype.stepEvalProgram_=function(a,b,d){var c=b.A||0;if(d=d.body[c])return b.A=c+1,new t(d,b.scope);a.pop();a[a.length-1].value=this.value};
|
||||
r.prototype.stepExpressionStatement=function(a,b,d){if(!b.S)return b.S=!0,new t(d.expression,b.scope);a.pop();this.value=b.value};
|
||||
r.prototype.stepForInStatement=function(a,b,d){if(!b.Lb&&(b.Lb=!0,d.left.declarations&&d.left.declarations[0].init))return b.scope.P&&J(this,this.ja,"for-in loop variable declaration may not have an initializer."),new t(d.left,b.scope);if(!b.va)return b.va=!0,b.ha||(b.ha=b.value),new t(d.right,b.scope);b.U||(b.U=!0,b.u=b.value,b.eb=Object.create(null));if(void 0===b.Ja)a:for(;;){if(b.u instanceof C)for(b.qa||(b.qa=Object.getOwnPropertyNames(b.u.h));;){var c=b.qa.shift();if(void 0===c)break;if(Object.prototype.hasOwnProperty.call(b.u.h,
|
||||
c)&&!b.eb[c]&&(b.eb[c]=!0,Object.prototype.propertyIsEnumerable.call(b.u.h,c))){b.Ja=c;break a}}else if(null!==b.u&&void 0!==b.u)for(b.qa||(b.qa=Object.getOwnPropertyNames(b.u));;){c=b.qa.shift();if(void 0===c)break;b.eb[c]=!0;if(Object.prototype.propertyIsEnumerable.call(b.u,c)){b.Ja=c;break a}}b.u=Gc(this,b.u);b.qa=null;if(null===b.u){a.pop();return}}if(!b.rb)if(b.rb=!0,a=d.left,"VariableDeclaration"===a.type)b.ha=[Oa,a.declarations[0].id.name];else return b.ha=null,b=new t(a,b.scope),b.ma=!0,b;
|
||||
b.ha||(b.ha=b.value);if(!b.oa&&(b.oa=!0,a=b.Ja,c=md(this,b.ha,a)))return pd(this,c,b.ha,a);b.Ja=void 0;b.rb=!1;b.oa=!1;if(d.body)return new t(d.body,b.scope)};r.prototype.stepForStatement=function(a,b,d){var c=b.ga||0;if(0===c){if(b.ga=1,d.init)return new t(d.init,b.scope)}else if(1===c){if(b.ga=2,d.test)return new t(d.test,b.scope)}else if(2===c)if(b.ga=3,d.test&&!b.value)a.pop();else return b.U=!0,new t(d.body,b.scope);else if(3===c&&(b.ga=1,d.update))return new t(d.update,b.scope)};
|
||||
r.prototype.stepFunctionDeclaration=function(a){a.pop()};r.prototype.stepFunctionExpression=function(a,b,d){a.pop();b=a[a.length-1];b.value=Dc(this,d,b.scope,b.Ia)};r.prototype.stepIdentifier=function(a,b,d){a.pop();if(b.ma)a[a.length-1].value=[Oa,d.name];else{b=jd(this,d.name);if(this.N)return od(this,b,this.Sa);a[a.length-1].value=b}};r.prototype.stepIfStatement=r.prototype.stepConditionalExpression;
|
||||
r.prototype.stepLabeledStatement=function(a,b,d){a.pop();a=b.labels||[];a.push(d.label.name);b=new t(d.body,b.scope);b.labels=a;return b};r.prototype.stepLiteral=function(a,b,d){a.pop();b=d.value;b instanceof RegExp&&(d=this.s(this.Fa),Nc(this,d,b),b=d);a[a.length-1].value=b};
|
||||
r.prototype.stepLogicalExpression=function(a,b,d){if("&&"!==d.operator&&"||"!==d.operator)throw SyntaxError("Unknown logical operator: "+d.operator);if(!b.ea)return b.ea=!0,new t(d.left,b.scope);if(b.wa)a.pop(),a[a.length-1].value=b.value;else if("&&"===d.operator&&!b.value||"||"===d.operator&&b.value)a.pop(),a[a.length-1].value=b.value;else return b.wa=!0,new t(d.right,b.scope)};
|
||||
r.prototype.stepMemberExpression=function(a,b,d){if(!b.va)return b.va=!0,new t(d.object,b.scope);if(d.computed)if(b.Mb)d=b.value;else return b.u=b.value,b.Mb=!0,new t(d.property,b.scope);else b.u=b.value,d=d.property.name;a.pop();if(b.ma)a[a.length-1].value=[b.u,d];else{d=this.D(b.u,d);if(this.N)return od(this,d,b.u);a[a.length-1].value=d}};r.prototype.stepNewExpression=r.prototype.stepCallExpression;
|
||||
r.prototype.stepObjectExpression=function(a,b,d){var c=b.A||0,e=d.properties[c];if(b.u){var g=b.Ia;b.Ca[g]||(b.Ca[g]={});b.Ca[g][e.kind]=b.value;b.A=++c;e=d.properties[c]}else b.u=this.s(this.L),b.Ca=Object.create(null);if(e){var l=e.key;if("Identifier"===l.type)g=l.name;else if("Literal"===l.type)g=l.value;else throw SyntaxError("Unknown object structure: "+l.type);b.Ia=g;return new t(e.value,b.scope)}for(l in b.Ca)d=b.Ca[l],"get"in d||"set"in d?this.g(b.u,l,Pa,{configurable:!0,enumerable:!0,get:d.get,
|
||||
set:d.set}):this.g(b.u,l,d.init);a.pop();a[a.length-1].value=b.u};r.prototype.stepProgram=function(a,b,d){if(a=d.body.shift())return b.done=!1,new t(a,b.scope);b.done=!0};r.prototype.stepReturnStatement=function(a,b,d){if(d.argument&&!b.S)return b.S=!0,new t(d.argument,b.scope);nd(this,3,b.value,void 0)};r.prototype.stepSequenceExpression=function(a,b,d){var c=b.A||0;if(d=d.expressions[c])return b.A=c+1,new t(d,b.scope);a.pop();a[a.length-1].value=b.value};
|
||||
r.prototype.stepSwitchStatement=function(a,b,d){if(!b.ca)return b.ca=1,new t(d.discriminant,b.scope);1===b.ca&&(b.ca=2,b.bc=b.value,b.Wa=-1);for(;;){var c=b.$a||0,e=d.cases[c];if(b.Aa||!e||e.test)if(e||b.Aa||-1===b.Wa)if(e){if(!b.Aa&&!b.yb&&e.test)return b.yb=!0,new t(e.test,b.scope);if(b.Aa||b.value===b.bc){b.Aa=!0;var g=b.A||0;if(e.consequent[g])return b.Tb=!0,b.A=g+1,new t(e.consequent[g],b.scope)}b.yb=!1;b.A=0;b.$a=c+1}else{a.pop();break}else b.Aa=!0,b.$a=b.Wa;else b.Wa=c,b.$a=c+1}};
|
||||
r.prototype.stepThisExpression=function(a){a.pop();a[a.length-1].value=jd(this,"this")};r.prototype.stepThrowStatement=function(a,b,d){if(b.S)J(this,b.value);else return b.S=!0,new t(d.argument,b.scope)};
|
||||
r.prototype.stepTryStatement=function(a,b,d){if(!b.Hb)return b.Hb=!0,new t(d.block,b.scope);if(b.aa&&4===b.aa.type&&!b.Kb&&d.handler)return b.Kb=!0,a=new t(d.handler,b.scope),a.cc=b.aa.value,b.aa=void 0,a;if(!b.Jb&&d.finalizer)return b.Jb=!0,new t(d.finalizer,b.scope);a.pop();b.aa&&nd(this,b.aa.type,b.aa.value,b.aa.label)};
|
||||
r.prototype.stepUnaryExpression=function(a,b,d){if(!b.S)return b.S=!0,a=new t(d.argument,b.scope),a.ma="delete"===d.operator,a;a.pop();var c=b.value;if("-"===d.operator)c=-c;else if("+"===d.operator)c=+c;else if("!"===d.operator)c=!c;else if("~"===d.operator)c=~c;else if("delete"===d.operator){d=!0;if(Array.isArray(c)){var e=c[0];e===Oa&&(e=b.scope);c=String(c[1]);try{delete e.h[c]}catch(g){b.scope.P?J(this,this.m,"Cannot delete property '"+c+"' of '"+e+"'"):d=!1}}c=d}else if("typeof"===d.operator)c=
|
||||
c&&"Function"===c.H?"function":typeof c;else if("void"===d.operator)c=void 0;else throw SyntaxError("Unknown unary operator: "+d.operator);a[a.length-1].value=c};
|
||||
r.prototype.stepUpdateExpression=function(a,b,d){if(!b.ea)return b.ea=!0,a=new t(d.argument,b.scope),a.ma=!0,a;b.za||(b.za=b.value);b.ua&&(b.fa=b.value);if(!b.ua){var c=ld(this,b.za);b.fa=c;if(this.N)return b.ua=!0,od(this,c,b.za)}if(b.oa)a.pop(),a[a.length-1].value=b.cb;else{c=Number(b.fa);if("++"===d.operator)var e=c+1;else if("--"===d.operator)e=c-1;else throw SyntaxError("Unknown update expression: "+d.operator);d=d.prefix?e:c;if(c=md(this,b.za,e))return b.oa=!0,b.cb=d,pd(this,c,b.za,e);a.pop();
|
||||
a[a.length-1].value=d}};r.prototype.stepVariableDeclaration=function(a,b,d){d=d.declarations;var c=b.A||0,e=d[c];b.vb&&e&&(kd(this,e.id.name,b.value),b.vb=!1,e=d[++c]);for(;e;){if(e.init)return b.A=c,b.vb=!0,b.Ia=e.id.name,new t(e.init,b.scope);e=d[++c]}a.pop()};r.prototype.stepWithStatement=function(a,b,d){if(b.va)if(b.Ib)a.pop();else return b.Ib=!0,a=id(this,b.scope,b.value),new t(d.body,a);else return b.va=!0,new t(d.object,b.scope)};r.prototype.stepWhileStatement=r.prototype.stepDoWhileStatement;
|
||||
this.Interpreter=r;r.prototype.step=r.prototype.fb;r.prototype.run=r.prototype.xb;r.prototype.appendCode=r.prototype.Bb;r.prototype.createObject=r.prototype.ta;r.prototype.createObjectProto=r.prototype.s;r.prototype.createAsyncFunction=r.prototype.ob;r.prototype.createNativeFunction=r.prototype.i;r.prototype.getProperty=r.prototype.D;r.prototype.setProperty=r.prototype.g;r.prototype.nativeToPseudo=r.prototype.Ba;r.prototype.pseudoToNative=r.prototype.O;r.prototype.getGlobalScope=r.prototype.Qb;
|
||||
r.prototype.getStateStack=r.prototype.Rb;r.prototype.setStateStack=r.prototype.$b;
|
||||
|
||||
Reference in New Issue
Block a user