Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

support source remapping with sourceURL

  • Loading branch information...
commit f5a81593282df8d06826a3962bccbe33e869b707 1 parent f048018
@substack authored
Showing with 5 additions and 5 deletions.
  1. +2 −2 package.json
  2. +1 −1  src/entry.js
  3. +1 −1  wreq.js
  4. +1 −1  wreq.min.js
View
4 package.json
@@ -1,10 +1,10 @@
{
"name" : "wreq",
- "version" : "0.0.0",
+ "version" : "0.0.1",
"scripts" : {
"install" : "bin/build.sh"
},
- "devDependencies" : {
+ "dependencies" : {
"browserify" : "1.9.x",
"detective" : "0.0.x",
"http-browserify" : "0.0.x",
View
2  src/entry.js
@@ -61,7 +61,7 @@ function fetch (file, cb) {
function store (file, data, cb) {
var requires = detective(data);
var pending = requires.length;
- sources[file].source = data;
+ sources[file].source = data + '\n//@ sourceURL=' + file;
sources[file].requires = {};
sources[file].run = function () {
return run(sources[file]);
View
2  wreq.js
@@ -4904,7 +4904,7 @@ function fetch (file, cb) {
function store (file, data, cb) {
var requires = detective(data);
var pending = requires.length;
- sources[file].source = data;
+ sources[file].source = data + '\n//@ sourceURL=' + file;
sources[file].requires = {};
sources[file].run = function () {
return run(sources[file]);
View
2  wreq.min.js
@@ -1,3 +1,3 @@
(function(){var require=function(a,b){var c=require.resolve(a,b||"/"),d=require.modules[c];if(!d)throw new Error("Failed to resolve module "+a+", tried "+c);var e=d._cached?d._cached:d();return e};require.paths=[],require.modules={},require.extensions=[".js",".coffee"],require._core={assert:!0,events:!0,fs:!0,path:!0,vm:!0},require.resolve=function(){return function(a,b){function g(a){if(require.modules[a])return a;for(var b=0;b<require.extensions.length;b++){var c=require.extensions[b];if(require.modules[a+c])return a+c}}function h(a){a=a.replace(/\/+$/,"");var b=a+"/package.json";if(require.modules[b]){var d=require.modules[b](),e=d.browserify;if(typeof e=="object"&&e.main){var f=g(c.resolve(a,e.main));if(f)return f}else if(typeof e=="string"){var f=g(c.resolve(a,e));if(f)return f}else if(d.main){var f=g(c.resolve(a,d.main));if(f)return f}}return g(a+"/index")}function i(a,b){var c=j(b);for(var d=0;d<c.length;d++){var e=c[d],f=g(e+"/"+a);if(f)return f;var i=h(e+"/"+a);if(i)return i}var f=g(a);if(f)return f}function j(a){var b;a==="/"?b=[""]:b=c.normalize(a).split("/");var d=[];for(var e=b.length-1;e>=0;e--){if(b[e]==="node_modules")continue;var f=b.slice(0,e+1).join("/")+"/node_modules";d.push(f)}return d}b||(b="/");if(require._core[a])return a;var c=require.modules.path(),d=b||".";if(a.match(/^(?:\.\.?\/|\/)/)){var e=g(c.resolve(d,a))||h(c.resolve(d,a));if(e)return e}var f=i(a,d);if(f)return f;throw new Error("Cannot find module '"+a+"'")}}(),require.alias=function(a,b){var c=require.modules.path(),d=null;try{d=require.resolve(a+"/package.json","/")}catch(e){d=require.resolve(a,"/")}var f=c.dirname(d),g=(Object.keys||function(a){var b=[];for(var c in a)b.push(c);return b})(require.modules);for(var h=0;h<g.length;h++){var i=g[h];if(i.slice(0,f.length+1)===f+"/"){var j=i.slice(f.length);require.modules[b+j]=require.modules[f+j]}else i===f&&(require.modules[b]=require.modules[f])}},require.define=function(a,b){var c=require._core[a]?"":require.modules.path().dirname(a),d=function(a){return require(a,c)};d.resolve=function(a){return require.resolve(a,c)},d.modules=require.modules,d.define=require.define;var e={exports:{}};require.modules[a]=function(){return require.modules[a]._cached=e.exports,b.call(e.exports,d,e,e.exports,c,a),require.modules[a]._cached=e.exports,e.exports}},typeof process=="undefined"&&(process={}),process.nextTick||(process.nextTick=function(){var a=[],b=typeof window!="undefined"&&window.postMessage&&window.addEventListener;return b&&window.addEventListener("message",function(b){if(b.source===window&&b.data==="browserify-tick"){b.stopPropagation();if(a.length>0){var c=a.shift();c()}}},!0),function(c){b?(a.push(c),window.postMessage("browserify-tick","*")):setTimeout(c,0)}}()),process.title||(process.title="browser"),process.binding||(process.binding=function(a){if(a==="evals")return require("vm");throw new Error("No such module")}),process.cwd||(process.cwd=function(){return"."}),require.define("path",function(a,b,c,d,e){function f(a,b){var c=[];for(var d=0;d<a.length;d++)b(a[d],d,a)&&c.push(a[d]);return c}function g(a,b){var c=0;for(var d=a.length;d>=0;d--){var e=a[d];e=="."?a.splice(d,1):e===".."?(a.splice(d,1),c++):c&&(a.splice(d,1),c--)}if(b)for(;c--;c)a.unshift("..");return a}var h=/^(.+\/(?!$)|\/)?((?:.+?)?(\.[^.]*)?)$/;c.resolve=function(){var a="",b=!1;for(var c=arguments.length;c>=-1&&!b;c--){var d=c>=0?arguments[c]:process.cwd();if(typeof d!="string"||!d)continue;a=d+"/"+a,b=d.charAt(0)==="/"}return a=g(f(a.split("/"),function(a){return!!a}),!b).join("/"),(b?"/":"")+a||"."},c.normalize=function(a){var b=a.charAt(0)==="/",c=a.slice(-1)==="/";return a=g(f(a.split("/"),function(a){return!!a}),!b).join("/"),!a&&!b&&(a="."),a&&c&&(a+="/"),(b?"/":"")+a},c.join=function(){var a=Array.prototype.slice.call(arguments,0);return c.normalize(f(a,function(a,b){return a&&typeof a=="string"}).join("/"))},c.dirname=function(a){var b=h.exec(a)[1]||"",c=!1;return b?b.length===1||c&&b.length<=3&&b.charAt(1)===":"?b:b.substring(0,b.length-1):"."},c.basename=function(a,b){var c=h.exec(a)[2]||"";return b&&c.substr(-1*b.length)===b&&(c=c.substr(0,c.length-b.length)),c},c.extname=function(a){return h.exec(a)[3]||""}}),require.define("/node_modules/detective/package.json",function(a,b,c,d,e){b.exports={main:"index.js"}}),require.define("/node_modules/detective/index.js",function(a,b,c,d,e){var f=a("burrito"),c=b.exports=function(a,b){return c.find(a,b).strings};c.find=function(a,b){b||(b={});var c=b.word===undefined?"require":b.word,d={strings:[],expressions:[]};return a.toString().indexOf(c)==-1?d:(f(a,function(a){var b=a.name==="call"&&a.value[0][0]==="name"&&a.value[0][1]===c;if(b){var e=a.value[1][0];e[0].name==="string"?d.strings.push(e[1]):d.expressions.push(f.deparse(e))}var g=(a.name==="dot"||a.name==="call")&&a.value[0][0]==="call"&&a.value[0][1][0]==="name"&&a.value[0][1][1]===c;if(g){var e=a.value[0][2][0];e[0].name==="string"?d.strings.push(e[1]):d.expressions.push(f.deparse(e))}var h=a.name==="call"&&a.value[0][0]==="dot"&&a.value[0][1][0]==="call"&&a.value[0][1][1][0]==="name"&&a.value[0][1][1][1]===c;if(h){var e=a.value[0][1][2][0];e[0].name==="string"?d.strings.push(e[1]):d.expressions.push(f.deparse(e))}}),d)}}),require.define("/node_modules/detective/node_modules/burrito/package.json",function(a,b,c,d,e){b.exports={main:"./index.js"}}),require.define("/node_modules/detective/node_modules/burrito/index.js",function(a,b,c,d,e){var f=a("uglify-js"),g=f.parser,h=function(a){if(typeof a!="string")throw"expression should be a string";try{var b=g.parse.apply(null,arguments)}catch(c){if(c.message===undefined||c.line===undefined||c.col===undefined||c.pos===undefined)throw c;var d=new SyntaxError(c.message+"\n at line "+c.line+":"+c.col+" in expression:\n\n"+" "+a.split(/\r?\n/)[c.line]);throw d.original=c,d.line=c.line,d.col=c.col,d.pos=c.pos,d}return b},i=function(a,b){return f.uglify.gen_code(a,{beautify:b})},j=a("traverse"),k=a("vm"),l=b.exports=function(a,b){var c=n(a)?a:h(a.toString(),!1,!0),d=j(c).map(function(){m(this,b)});return i(h(i(d)),!0)},m=l.wrapNode=function(a,b){var c=a.node,d=n(c)&&c[0]&&typeof c[0]=="object"&&c[0].name?c[0]:null;if(!d)return undefined;var e={name:d.name,node:c,start:c[0].start,end:c[0].end,value:c.slice(1),state:a};e.wrap=function(d){var f=i(j(c).map(function(a){this.isRoot||m(this,b)}));if(e.name==="binary")var g=i(j(c[2]).map(function(a){this.isRoot||m(this,b)})),k=i(j(c[3]).map(function(a){this.isRoot||m(this,b)}));var l="";typeof d=="function"?e.name==="binary"?l=d(f,g,k):l=d(f):(l=d.toString().replace(/undefined/g,function(){return f}),e.name==="binary"&&(l=l.replace(/%a/g,function(){return g}).replace(/%b/g,function(){return k})));var n=h(l);a.update(n,!0)};var f={};return e.parent=a.isRoot?null:function(){if(!f.parent){var b=a,c;do b=b.parent,b&&(c=m(b));while(b&&!c);f.parent=c}return f.parent},e.source=function(){return f.source||(f.source=i(c)),f.source},e.label=function(){return l.label(e)},b&&b.call(a,e),e.node[0].name==="conditional"&&e.wrap("[undefined][0]"),e};l.microwave=function(a,b,c){c||(c=b,b={}),b||(b={});var d=l(a,c);return k.runInNewContext(d,b)},l.generateName=function(a){var b="",c="$".charCodeAt(0),d="z".charCodeAt(0);while(b.length<a){var e=String.fromCharCode(Math.floor(Math.random()*(d-c+1)+c));(b+e).match(/^[A-Za-z_$][A-Za-z0-9_$]*$/)&&(b+=e)}return b},l.parse=h,l.deparse=i,l.label=function(a){return a.name==="call"?typeof a.value[0]=="string"?a.value[0]:a.value[0]&&typeof a.value[0][1]=="string"?a.value[0][1]:a.value[0][0]==="dot"?a.value[0][a.value[0].length-1]:null:a.name==="var"?a.value[0].map(function(a){return a[0]}):a.name==="defun"?a.value[0]:a.name==="function"?a.value[0]:null};var n=Array.isArray||function(b){return Object.prototype.toString.call(b)==="[object Array]"}}),require.define("/node_modules/detective/node_modules/burrito/node_modules/uglify-js/package.json",function(a,b,c,d,e){b.exports={main:"./uglify-js.js"}}),require.define("/node_modules/detective/node_modules/burrito/node_modules/uglify-js/uglify-js.js",function(a,b,c,d,e){function f(a,b){b||(b={});var c=f.parser,d=f.uglify,e=c.parse(a,b.strict_semicolons);e=d.ast_mangle(e,b.mangle_options),e=d.ast_squeeze(e,b.squeeze_options);var g=d.gen_code(e,b.gen_options);return g}f.parser=a("./lib/parse-js"),f.uglify=a("./lib/process"),b.exports=f}),require.define("/node_modules/detective/node_modules/burrito/node_modules/uglify-js/lib/parse-js.js",function(a,b,c,d,e){function t(a){return s.letter.test(a)}function u(a){return a=a.charCodeAt(0),a>=48&&a<=57}function v(a){return u(a)||t(a)}function w(a){return s.non_spacing_mark.test(a)||s.space_combining_mark.test(a)}function x(a){return s.connector_punctuation.test(a)}function y(a){return a=="$"||a=="_"||t(a)}function z(a){return y(a)||w(a)||u(a)||x(a)||a=="‌"||a=="‍"}function A(a){if(k.test(a))return parseInt(a.substr(2),16);if(l.test(a))return parseInt(a.substr(1),8);if(m.test(a))return parseFloat(a)}function B(a,b,c,d){this.message=a,this.line=b,this.col=c,this.pos=d;try{({})()}catch(e){this.stack=e.stack}}function C(a,b,c,d){throw new B(a,b,c,d)}function D(a,b,c){return a.type==b&&(c==null||a.value==c)}function F(a){function c(){return b.text.charAt(b.pos)}function d(a){var c=b.text.charAt(b.pos++);if(a&&!c)throw E;return c=="\n"?(b.newline_before=!0,++b.line,b.col=0):++b.col,c}function e(){return!b.peek()}function g(a,c){var d=b.text.indexOf(a,b.pos);if(c&&d==-1)throw E;return d}function k(){b.tokline=b.line,b.tokcol=b.col,b.tokpos=b.pos}function l(a,c,d){b.regex_allowed=a=="operator"&&!U(H,c)||a=="keyword"&&U(h,c)||a=="punc"&&U(p,c);var e={type:a,value:c,line:b.tokline,col:b.tokcol,pos:b.tokpos,nlb:b.newline_before};return d||(e.comments_before=b.comments_before,b.comments_before=[]),b.newline_before=!1,e}function m(){while(U(o,c()))d()}function r(a){var b="",e=c(),f=0;while(e&&a(e,f++))b+=d(),e=c();return b}function s(a){C(a,b.tokline,b.tokcol,b.tokpos)}function t(a){var b=!1,c=!1,d=!1,e=a==".",f=r(function(f,g){return f=="x"||f=="X"?d?!1:d=!0:!!d||f!="E"&&f!="e"?f=="-"?c||g==0&&!a?!0:!1:f=="+"?c:(c=!1,f=="."?!e&&!d?e=!0:!1:v(f)):b?!1:b=c=!0});a&&(f=a+f);var g=A(f);if(!isNaN(g))return l("num",g);s("Invalid syntax: "+f)}function w(){var a=d(!0);switch(a){case"n":return"\n";case"r":return"\r";case"t":return"\t";case"b":return"\b";case"v":return" ";case"f":return"\f";case"0":return"\0";case"x":return String.fromCharCode(x(2));case"u":return String.fromCharCode(x(4));case"\n":return"";default:return a}}function x(a){var b=0;for(;a>0;--a){var c=parseInt(d(!0),16);isNaN(c)&&s("Invalid hex-character pattern in string"),b=b<<4|c}return b}function B(){return N("Unterminated string constant",function(){var a=d(),b="";for(;;){var c=d(!0);if(c=="\\"){var e=0,f=null;c=r(function(a){if(a>="0"&&a<="7"){if(!f)return f=a,++e;if(f<="3"&&e<=2)return++e;if(f>="4"&&e<=1)return++e}return!1}),e>0?c=String.fromCharCode(parseInt(c,8)):c=w()}else if(c==a)break;b+=c}return l("string",b)})}function D(){d();var a=g("\n"),c;return a==-1?(c=b.text.substr(b.pos),b.pos=b.text.length):(c=b.text.substring(b.pos,a),b.pos=a),l("comment1",c,!0)}function F(){return d(),N("Unterminated multiline comment",function(){var a=g("*/",!0),c=b.text.substring(b.pos,a),d=l("comment2",c,!0);return b.pos=a+2,b.line+=c.split("\n").length-1,b.newline_before=c.indexOf("\n")>=0,/^@cc_on/i.test(c)&&(V("WARNING: at line "+b.line),V('*** Found "conditional comment": '+c),V("*** UglifyJS DISCARDS ALL COMMENTS. This means your code might no longer work properly in Internet Explorer.")),d})}function G(){var a=!1,b="",e;while((e=c())!=null)if(!a)if(e=="\\")a=!0,d();else{if(!z(e))break;b+=d()}else e!="u"&&s("Expecting UnicodeEscapeSequence -- uXXXX"),e=w(),z(e)||s("Unicode char: "+e.charCodeAt(0)+" is not valid in identifier"),b+=e,a=!1;return b}function I(){return N("Unterminated regular expression",function(){var a=!1,b="",c,e=!1;while(c=d(!0))if(a)b+="\\"+c,a=!1;else if(c=="[")e=!0,b+=c;else if(c=="]"&&e)e=!1,b+=c;else{if(c=="/"&&!e)break;c=="\\"?a=!0:b+=c}var f=G();return l("regexp",[b,f])})}function J(a){function b(a){if(!c())return a;var e=a+c();return U(n,e)?(d(),b(e)):a}return l("operator",b(a||d()))}function K(){d();var a=b.regex_allowed;switch(c()){case"/":return b.comments_before.push(D()),b.regex_allowed=a,O();case"*":return b.comments_before.push(F()),b.regex_allowed=a,O()}return b.regex_allowed?I():J("/")}function L(){return d(),u(c())?t("."):l("punc",".")}function M(){var a=G();return U(f,a)?U(n,a)?l("operator",a):U(i,a)?l("atom",a):l("keyword",a):l("name",a)}function N(a,b){try{return b()}catch(c){if(c!==E)throw c;s(a)}}function O(a){if(a)return I();m(),k();var b=c();if(!b)return l("eof");if(u(b))return t();if(b=='"'||b=="'")return B();if(U(q,b))return l("punc",d());if(b==".")return L();if(b=="/")return K();if(U(j,b))return J();if(b=="\\"||y(b))return M();s("Unexpected character '"+b+"'")}var b={text:a.replace(/\r\n?|[\n\u2028\u2029]/g,"\n").replace(/^\uFEFF/,""),pos:0,tokpos:0,line:0,tokline:0,col:0,tokcol:0,newline_before:!1,regex_allowed:!1,comments_before:[]};return O.context=function(a){return a&&(b=a),b},O}function M(a,b,c){this.name=a,this.start=b,this.end=c}function N(a,b,c){function e(a,b){return D(d.token,a,b)}function f(){return d.peeked||(d.peeked=d.input())}function g(){return d.prev=d.token,d.peeked?(d.token=d.peeked,d.peeked=null):d.token=d.input(),d.token}function h(){return d.prev}function i(a,b,c,e){var f=d.input.context();C(a,b!=null?b:f.tokline,c!=null?c:f.tokcol,e!=null?e:f.tokpos)}function j(a,b){i(b,a.line,a.col)}function k(a){a==null&&(a=d.token),j(a,"Unexpected token: "+a.type+" ("+a.value+")")}function l(a,b){if(e(a,b))return g();j(d.token,"Unexpected token "+d.token.type+", expected "+a)}function m(a){return l("punc",a)}function n(){return!b&&(d.token.nlb||e("eof")||e("punc","}"))}function o(){e("punc",";")?g():n()||k()}function p(){return R(arguments)}function q(){m("(");var a=bk();return m(")"),a}function r(a,b,c){return a instanceof M?a:new M(a,b,c)}function s(a){return c?function(){var b=d.token,c=a.apply(this,arguments);return c[0]=r(c[0],b,h()),c}:a}function u(a){d.labels.push(a);var c=d.token,e=t();return b&&!U(K,e[0])&&k(c),d.labels.pop(),p("label",a,e)}function v(){return p("stat",P(bk,o))}function w(a){var b;return n()||(b=e("name")?d.token.value:null),b!=null?(g(),T(b,d.labels)||i("Label "+b+" without matching loop or statement")):d.in_loop==0&&i(a+" not inside a loop or switch"),o(),p(a,b)}function x(){m("(");var a=null;if(!e("punc",";")){a=e("keyword","var")?(g(),V(!0)):bk(!0,!0);if(e("operator","in"))return z(a)}return y(a)}function y(a){m(";");var b=e("punc",";")?null:bk();m(";");var c=e("punc",")")?null:bk();return m(")"),p("for",a,b,c,bl(t))}function z(a){var b=a[0]=="var"?p("name",a[1][0]):a;g();var c=bk();return m(")"),p("for-in",a,b,c,bl(t))}function B(){var a=q(),b=t(),c;return e("keyword","else")&&(g(),c=t()),p("if",a,b,c)}function E(){m("{");var a=[];while(!e("punc","}"))e("eof")&&k(),a.push(t());return g(),a}function Q(){var a=E(),b,c;if(e("keyword","catch")){g(),m("("),e("name")||i("Name expected");var f=d.token.value;g(),m(")"),b=[f,E()]}return e("keyword","finally")&&(g(),c=E()),!b&&!c&&i("Missing catch/finally blocks"),p("try",a,b,c)}function S(a){var b=[];for(;;){e("name")||k();var c=d.token.value;g(),e("operator","=")?(g(),b.push([c,bk(!1,a)])):b.push([c]);if(!e("punc",","))break;g()}return b}function V(a){return p("var",S(a))}function W(){return p("const",S())}function X(){var a=Y(!1),b;return e("punc","(")?(g(),b=Z(")")):b=[],bc(p("new",a,b),!0)}function Z(a,b,c){var d=!0,f=[];while(!e("punc",a)){d?d=!1:m(",");if(b&&e("punc",a))break;e("punc",",")&&c?f.push(["atom","undefined"]):f.push(bk(!1))}return g(),f}function $(){return p("array",Z("]",!b,!0))}function _(){var a=!0,c=[];while(!e("punc","}")){a?a=!1:m(",");if(!b&&e("punc","}"))break;var f=d.token.type,h=ba();f!="name"||h!="get"&&h!="set"||!!e("punc",":")?(m(":"),c.push([h,bk(!1)])):c.push([bb(),A(!1),h])}return g(),p("object",c)}function ba(){switch(d.token.type){case"num":case"string":return P(d.token.value,g)}return bb()}function bb(){switch(d.token.type){case"name":case"operator":case"keyword":case"atom":return P(d.token.value,g);default:k()}}function bc(a,b){return e("punc",".")?(g(),bc(p("dot",a,bb()),b)):e("punc","[")?(g(),bc(p("sub",a,P(bk,O(m,"]"))),b)):b&&e("punc","(")?(g(),bc(p("call",a,Z(")")),!0)):a}function bd(a){if(e("operator")&&U(G,d.token.value))return be("unary-prefix",P(d.token.value,g),bd(a));var b=Y(a);while(e("operator")&&U(H,d.token.value)&&!d.token.nlb)b=be("unary-postfix",d.token.value,b),g();return b}function be(a,b,c){return(b=="++"||b=="--")&&!bi(c)&&i("Invalid use of "+b+" operator"),p(a,b,c)}function bf(a,b,c){var f=e("operator")?d.token.value:null;f&&f=="in"&&c&&(f=null);var h=f!=null?J[f]:null;if(h!=null&&h>b){g();var i=bf(bd(!0),h,c);return bf(p("binary",f,a,i),b,c)}return a}function bg(a){return bf(bd(!0),0,a)}function bh(a){var b=bg(a);if(e("operator","?")){g();var c=bk(!1);return m(":"),p("conditional",b,c,bk(!1,a))}return b}function bi(a){if(!b)return!0;switch(a[0]){case"dot":case"sub":case"new":case"call":return!0;case"name":return a[1]!="this"}}function bj(a){var b=bh(a),c=d.token.value;if(e("operator")&&U(I,c)){if(bi(b))return g(),p("assign",I[c],b,bj(a));i("Invalid assignment")}return b}function bl(a){try{return++d.in_loop,a()}finally{--d.in_loop}}var d={input:typeof a=="string"?F(a,!0):a,token:null,prev:null,peeked:null,in_function:0,in_loop:0,labels:[]};d.token=g();var t=s(function(){e("operator","/")&&(d.peeked=null,d.token=d.input(!0));switch(d.token.type){case"num":case"string":case"regexp":case"operator":case"atom":return v();case"name":return D(f(),"punc",":")?u(P(d.token.value,g,g)):v();case"punc":switch(d.token.value){case"{":return p("block",E());case"[":case"(":return v();case";":return g(),p("block");default:k()};case"keyword":switch(P(d.token.value,g)){case"break":return w("break");case"continue":return w("continue");case"debugger":return o(),p("debugger");case"do":return function(a){return l("keyword","while"),p("do",P(q,o),a)}(bl(t));case"for":return x();case"function":return A(!0);case"if":return B();case"return":return d.in_function==0&&i("'return' outside of function"),p("return",e("punc",";")?(g(),null):n()?null:P(bk,o));case"switch":return p("switch",q(),N());case"throw":return p("throw",P(bk,o));case"try":return Q();case"var":return P(V,o);case"const":return P(W,o);case"while":return p("while",q(),bl(t));case"with":return p("with",q(),t());default:k()}}}),A=s(function(a){var b=e("name")?P(d.token.value,g):null;return a&&!b&&k(),m("("),p(a?"defun":"function",b,function(a,b){while(!e("punc",")"))a?a=!1:m(","),e("name")||k(),b.push(d.token.value),g();return g(),b}(!0,[]),function(){++d.in_function;var a=d.in_loop;d.in_loop=0;var b=E();return--d.in_function,d.in_loop=a,b}())}),N=O(bl,function(){m("{");var a=[],b=null;while(!e("punc","}"))e("eof")&&k(),e("keyword","case")?(g(),b=[],a.push([bk(),b]),m(":")):e("keyword","default")?(g(),m(":"),b=[],a.push([null,b])):(b||k(),b.push(t()));return g(),a}),Y=s(function(a){if(e("operator","new"))return g(),X();if(e("punc")){switch(d.token.value){case"(":return g(),bc(P(bk,O(m,")")),a);case"[":return g(),bc($(),a);case"{":return g(),bc(_(),a)}k()}if(e("keyword","function"))return g(),bc(A(!1),a);if(U(L,d.token.type)){var b=d.token.type=="regexp"?p("regexp",d.token.value[0],d.token.value[1]):p(d.token.type,d.token.value);return bc(P(b,g),a)}k()}),bk=s(function(a,b){arguments.length==0&&(a=!0);var c=bj(b);return a&&e("punc",",")?(g(),p("seq",c,bk(!0,b))):c});return p("toplevel",function(a){while(!e("eof"))a.push(t());return a}([]))}function O(a){var b=R(arguments,1);return function(){return a.apply(this,b.concat(R(arguments)))}}function P(a){a instanceof Function&&(a=a());for(var b=1,c=arguments.length;--c>0;++b)arguments[b]();return a}function Q(a){var b={};for(var c=0;c<a.length;++c)b[a[c]]=!0;return b}function R(a,b){return Array.prototype.slice.call(a,b||0)}function S(a){return a.split("")}function T(a,b){for(var c=b.length;--c>=0;)if(b[c]===a)return!0;return!1}function U(a,b){return Object.prototype.hasOwnProperty.call(a,b)}var f=Q(["break","case","catch","const","continue","default","delete","do","else","finally","for","function","if","in","instanceof","new","return","switch","throw","try","typeof","var","void","while","with"]),g=Q(["abstract","boolean","byte","char","class","debugger","double","enum","export","extends","final","float","goto","implements","import","int","interface","long","native","package","private","protected","public","short","static","super","synchronized","throws","transient","volatile"]),h=Q(["return","new","delete","throw","else","case"]),i=Q(["false","null","true","undefined"]),j=Q(S("+-*&%=<>!?|~^")),k=/^0x[0-9a-f]+$/i,l=/^0[0-7]+$/,m=/^\d*\.?\d*(?:e[+-]?\d*(?:\d\.?|\.?\d)\d*)?$/i,n=Q(["in","instanceof","typeof","new","void","delete","++","--","+","-","!","~","&","|","^","*","/","%",">>","<<",">>>","<",">","<=",">=","==","===","!=","!==","?","=","+=","-=","/=","*=","%=",">>=","<<=",">>>=","|=","^=","&=","&&","||"]),o=Q(S("  \n\r\t\f ​")),p=Q(S("[{}(,.;:")),q=Q(S("[]{}(),;:")),r=Q(S("gmsiy")),s={letter:new RegExp("[\\u0041-\\u005A\\u0061-\\u007A\\u00AA\\u00B5\\u00BA\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02C1\\u02C6-\\u02D1\\u02E0-\\u02E4\\u02EC\\u02EE\\u0370-\\u0374\\u0376\\u0377\\u037A-\\u037D\\u0386\\u0388-\\u038A\\u038C\\u038E-\\u03A1\\u03A3-\\u03F5\\u03F7-\\u0481\\u048A-\\u0523\\u0531-\\u0556\\u0559\\u0561-\\u0587\\u05D0-\\u05EA\\u05F0-\\u05F2\\u0621-\\u064A\\u066E\\u066F\\u0671-\\u06D3\\u06D5\\u06E5\\u06E6\\u06EE\\u06EF\\u06FA-\\u06FC\\u06FF\\u0710\\u0712-\\u072F\\u074D-\\u07A5\\u07B1\\u07CA-\\u07EA\\u07F4\\u07F5\\u07FA\\u0904-\\u0939\\u093D\\u0950\\u0958-\\u0961\\u0971\\u0972\\u097B-\\u097F\\u0985-\\u098C\\u098F\\u0990\\u0993-\\u09A8\\u09AA-\\u09B0\\u09B2\\u09B6-\\u09B9\\u09BD\\u09CE\\u09DC\\u09DD\\u09DF-\\u09E1\\u09F0\\u09F1\\u0A05-\\u0A0A\\u0A0F\\u0A10\\u0A13-\\u0A28\\u0A2A-\\u0A30\\u0A32\\u0A33\\u0A35\\u0A36\\u0A38\\u0A39\\u0A59-\\u0A5C\\u0A5E\\u0A72-\\u0A74\\u0A85-\\u0A8D\\u0A8F-\\u0A91\\u0A93-\\u0AA8\\u0AAA-\\u0AB0\\u0AB2\\u0AB3\\u0AB5-\\u0AB9\\u0ABD\\u0AD0\\u0AE0\\u0AE1\\u0B05-\\u0B0C\\u0B0F\\u0B10\\u0B13-\\u0B28\\u0B2A-\\u0B30\\u0B32\\u0B33\\u0B35-\\u0B39\\u0B3D\\u0B5C\\u0B5D\\u0B5F-\\u0B61\\u0B71\\u0B83\\u0B85-\\u0B8A\\u0B8E-\\u0B90\\u0B92-\\u0B95\\u0B99\\u0B9A\\u0B9C\\u0B9E\\u0B9F\\u0BA3\\u0BA4\\u0BA8-\\u0BAA\\u0BAE-\\u0BB9\\u0BD0\\u0C05-\\u0C0C\\u0C0E-\\u0C10\\u0C12-\\u0C28\\u0C2A-\\u0C33\\u0C35-\\u0C39\\u0C3D\\u0C58\\u0C59\\u0C60\\u0C61\\u0C85-\\u0C8C\\u0C8E-\\u0C90\\u0C92-\\u0CA8\\u0CAA-\\u0CB3\\u0CB5-\\u0CB9\\u0CBD\\u0CDE\\u0CE0\\u0CE1\\u0D05-\\u0D0C\\u0D0E-\\u0D10\\u0D12-\\u0D28\\u0D2A-\\u0D39\\u0D3D\\u0D60\\u0D61\\u0D7A-\\u0D7F\\u0D85-\\u0D96\\u0D9A-\\u0DB1\\u0DB3-\\u0DBB\\u0DBD\\u0DC0-\\u0DC6\\u0E01-\\u0E30\\u0E32\\u0E33\\u0E40-\\u0E46\\u0E81\\u0E82\\u0E84\\u0E87\\u0E88\\u0E8A\\u0E8D\\u0E94-\\u0E97\\u0E99-\\u0E9F\\u0EA1-\\u0EA3\\u0EA5\\u0EA7\\u0EAA\\u0EAB\\u0EAD-\\u0EB0\\u0EB2\\u0EB3\\u0EBD\\u0EC0-\\u0EC4\\u0EC6\\u0EDC\\u0EDD\\u0F00\\u0F40-\\u0F47\\u0F49-\\u0F6C\\u0F88-\\u0F8B\\u1000-\\u102A\\u103F\\u1050-\\u1055\\u105A-\\u105D\\u1061\\u1065\\u1066\\u106E-\\u1070\\u1075-\\u1081\\u108E\\u10A0-\\u10C5\\u10D0-\\u10FA\\u10FC\\u1100-\\u1159\\u115F-\\u11A2\\u11A8-\\u11F9\\u1200-\\u1248\\u124A-\\u124D\\u1250-\\u1256\\u1258\\u125A-\\u125D\\u1260-\\u1288\\u128A-\\u128D\\u1290-\\u12B0\\u12B2-\\u12B5\\u12B8-\\u12BE\\u12C0\\u12C2-\\u12C5\\u12C8-\\u12D6\\u12D8-\\u1310\\u1312-\\u1315\\u1318-\\u135A\\u1380-\\u138F\\u13A0-\\u13F4\\u1401-\\u166C\\u166F-\\u1676\\u1681-\\u169A\\u16A0-\\u16EA\\u1700-\\u170C\\u170E-\\u1711\\u1720-\\u1731\\u1740-\\u1751\\u1760-\\u176C\\u176E-\\u1770\\u1780-\\u17B3\\u17D7\\u17DC\\u1820-\\u1877\\u1880-\\u18A8\\u18AA\\u1900-\\u191C\\u1950-\\u196D\\u1970-\\u1974\\u1980-\\u19A9\\u19C1-\\u19C7\\u1A00-\\u1A16\\u1B05-\\u1B33\\u1B45-\\u1B4B\\u1B83-\\u1BA0\\u1BAE\\u1BAF\\u1C00-\\u1C23\\u1C4D-\\u1C4F\\u1C5A-\\u1C7D\\u1D00-\\u1DBF\\u1E00-\\u1F15\\u1F18-\\u1F1D\\u1F20-\\u1F45\\u1F48-\\u1F4D\\u1F50-\\u1F57\\u1F59\\u1F5B\\u1F5D\\u1F5F-\\u1F7D\\u1F80-\\u1FB4\\u1FB6-\\u1FBC\\u1FBE\\u1FC2-\\u1FC4\\u1FC6-\\u1FCC\\u1FD0-\\u1FD3\\u1FD6-\\u1FDB\\u1FE0-\\u1FEC\\u1FF2-\\u1FF4\\u1FF6-\\u1FFC\\u2071\\u207F\\u2090-\\u2094\\u2102\\u2107\\u210A-\\u2113\\u2115\\u2119-\\u211D\\u2124\\u2126\\u2128\\u212A-\\u212D\\u212F-\\u2139\\u213C-\\u213F\\u2145-\\u2149\\u214E\\u2183\\u2184\\u2C00-\\u2C2E\\u2C30-\\u2C5E\\u2C60-\\u2C6F\\u2C71-\\u2C7D\\u2C80-\\u2CE4\\u2D00-\\u2D25\\u2D30-\\u2D65\\u2D6F\\u2D80-\\u2D96\\u2DA0-\\u2DA6\\u2DA8-\\u2DAE\\u2DB0-\\u2DB6\\u2DB8-\\u2DBE\\u2DC0-\\u2DC6\\u2DC8-\\u2DCE\\u2DD0-\\u2DD6\\u2DD8-\\u2DDE\\u2E2F\\u3005\\u3006\\u3031-\\u3035\\u303B\\u303C\\u3041-\\u3096\\u309D-\\u309F\\u30A1-\\u30FA\\u30FC-\\u30FF\\u3105-\\u312D\\u3131-\\u318E\\u31A0-\\u31B7\\u31F0-\\u31FF\\u3400\\u4DB5\\u4E00\\u9FC3\\uA000-\\uA48C\\uA500-\\uA60C\\uA610-\\uA61F\\uA62A\\uA62B\\uA640-\\uA65F\\uA662-\\uA66E\\uA67F-\\uA697\\uA717-\\uA71F\\uA722-\\uA788\\uA78B\\uA78C\\uA7FB-\\uA801\\uA803-\\uA805\\uA807-\\uA80A\\uA80C-\\uA822\\uA840-\\uA873\\uA882-\\uA8B3\\uA90A-\\uA925\\uA930-\\uA946\\uAA00-\\uAA28\\uAA40-\\uAA42\\uAA44-\\uAA4B\\uAC00\\uD7A3\\uF900-\\uFA2D\\uFA30-\\uFA6A\\uFA70-\\uFAD9\\uFB00-\\uFB06\\uFB13-\\uFB17\\uFB1D\\uFB1F-\\uFB28\\uFB2A-\\uFB36\\uFB38-\\uFB3C\\uFB3E\\uFB40\\uFB41\\uFB43\\uFB44\\uFB46-\\uFBB1\\uFBD3-\\uFD3D\\uFD50-\\uFD8F\\uFD92-\\uFDC7\\uFDF0-\\uFDFB\\uFE70-\\uFE74\\uFE76-\\uFEFC\\uFF21-\\uFF3A\\uFF41-\\uFF5A\\uFF66-\\uFFBE\\uFFC2-\\uFFC7\\uFFCA-\\uFFCF\\uFFD2-\\uFFD7\\uFFDA-\\uFFDC]"),non_spacing_mark:new RegExp("[\\u0300-\\u036F\\u0483-\\u0487\\u0591-\\u05BD\\u05BF\\u05C1\\u05C2\\u05C4\\u05C5\\u05C7\\u0610-\\u061A\\u064B-\\u065E\\u0670\\u06D6-\\u06DC\\u06DF-\\u06E4\\u06E7\\u06E8\\u06EA-\\u06ED\\u0711\\u0730-\\u074A\\u07A6-\\u07B0\\u07EB-\\u07F3\\u0816-\\u0819\\u081B-\\u0823\\u0825-\\u0827\\u0829-\\u082D\\u0900-\\u0902\\u093C\\u0941-\\u0948\\u094D\\u0951-\\u0955\\u0962\\u0963\\u0981\\u09BC\\u09C1-\\u09C4\\u09CD\\u09E2\\u09E3\\u0A01\\u0A02\\u0A3C\\u0A41\\u0A42\\u0A47\\u0A48\\u0A4B-\\u0A4D\\u0A51\\u0A70\\u0A71\\u0A75\\u0A81\\u0A82\\u0ABC\\u0AC1-\\u0AC5\\u0AC7\\u0AC8\\u0ACD\\u0AE2\\u0AE3\\u0B01\\u0B3C\\u0B3F\\u0B41-\\u0B44\\u0B4D\\u0B56\\u0B62\\u0B63\\u0B82\\u0BC0\\u0BCD\\u0C3E-\\u0C40\\u0C46-\\u0C48\\u0C4A-\\u0C4D\\u0C55\\u0C56\\u0C62\\u0C63\\u0CBC\\u0CBF\\u0CC6\\u0CCC\\u0CCD\\u0CE2\\u0CE3\\u0D41-\\u0D44\\u0D4D\\u0D62\\u0D63\\u0DCA\\u0DD2-\\u0DD4\\u0DD6\\u0E31\\u0E34-\\u0E3A\\u0E47-\\u0E4E\\u0EB1\\u0EB4-\\u0EB9\\u0EBB\\u0EBC\\u0EC8-\\u0ECD\\u0F18\\u0F19\\u0F35\\u0F37\\u0F39\\u0F71-\\u0F7E\\u0F80-\\u0F84\\u0F86\\u0F87\\u0F90-\\u0F97\\u0F99-\\u0FBC\\u0FC6\\u102D-\\u1030\\u1032-\\u1037\\u1039\\u103A\\u103D\\u103E\\u1058\\u1059\\u105E-\\u1060\\u1071-\\u1074\\u1082\\u1085\\u1086\\u108D\\u109D\\u135F\\u1712-\\u1714\\u1732-\\u1734\\u1752\\u1753\\u1772\\u1773\\u17B7-\\u17BD\\u17C6\\u17C9-\\u17D3\\u17DD\\u180B-\\u180D\\u18A9\\u1920-\\u1922\\u1927\\u1928\\u1932\\u1939-\\u193B\\u1A17\\u1A18\\u1A56\\u1A58-\\u1A5E\\u1A60\\u1A62\\u1A65-\\u1A6C\\u1A73-\\u1A7C\\u1A7F\\u1B00-\\u1B03\\u1B34\\u1B36-\\u1B3A\\u1B3C\\u1B42\\u1B6B-\\u1B73\\u1B80\\u1B81\\u1BA2-\\u1BA5\\u1BA8\\u1BA9\\u1C2C-\\u1C33\\u1C36\\u1C37\\u1CD0-\\u1CD2\\u1CD4-\\u1CE0\\u1CE2-\\u1CE8\\u1CED\\u1DC0-\\u1DE6\\u1DFD-\\u1DFF\\u20D0-\\u20DC\\u20E1\\u20E5-\\u20F0\\u2CEF-\\u2CF1\\u2DE0-\\u2DFF\\u302A-\\u302F\\u3099\\u309A\\uA66F\\uA67C\\uA67D\\uA6F0\\uA6F1\\uA802\\uA806\\uA80B\\uA825\\uA826\\uA8C4\\uA8E0-\\uA8F1\\uA926-\\uA92D\\uA947-\\uA951\\uA980-\\uA982\\uA9B3\\uA9B6-\\uA9B9\\uA9BC\\uAA29-\\uAA2E\\uAA31\\uAA32\\uAA35\\uAA36\\uAA43\\uAA4C\\uAAB0\\uAAB2-\\uAAB4\\uAAB7\\uAAB8\\uAABE\\uAABF\\uAAC1\\uABE5\\uABE8\\uABED\\uFB1E\\uFE00-\\uFE0F\\uFE20-\\uFE26]"),space_combining_mark:new RegExp("[\\u0903\\u093E-\\u0940\\u0949-\\u094C\\u094E\\u0982\\u0983\\u09BE-\\u09C0\\u09C7\\u09C8\\u09CB\\u09CC\\u09D7\\u0A03\\u0A3E-\\u0A40\\u0A83\\u0ABE-\\u0AC0\\u0AC9\\u0ACB\\u0ACC\\u0B02\\u0B03\\u0B3E\\u0B40\\u0B47\\u0B48\\u0B4B\\u0B4C\\u0B57\\u0BBE\\u0BBF\\u0BC1\\u0BC2\\u0BC6-\\u0BC8\\u0BCA-\\u0BCC\\u0BD7\\u0C01-\\u0C03\\u0C41-\\u0C44\\u0C82\\u0C83\\u0CBE\\u0CC0-\\u0CC4\\u0CC7\\u0CC8\\u0CCA\\u0CCB\\u0CD5\\u0CD6\\u0D02\\u0D03\\u0D3E-\\u0D40\\u0D46-\\u0D48\\u0D4A-\\u0D4C\\u0D57\\u0D82\\u0D83\\u0DCF-\\u0DD1\\u0DD8-\\u0DDF\\u0DF2\\u0DF3\\u0F3E\\u0F3F\\u0F7F\\u102B\\u102C\\u1031\\u1038\\u103B\\u103C\\u1056\\u1057\\u1062-\\u1064\\u1067-\\u106D\\u1083\\u1084\\u1087-\\u108C\\u108F\\u109A-\\u109C\\u17B6\\u17BE-\\u17C5\\u17C7\\u17C8\\u1923-\\u1926\\u1929-\\u192B\\u1930\\u1931\\u1933-\\u1938\\u19B0-\\u19C0\\u19C8\\u19C9\\u1A19-\\u1A1B\\u1A55\\u1A57\\u1A61\\u1A63\\u1A64\\u1A6D-\\u1A72\\u1B04\\u1B35\\u1B3B\\u1B3D-\\u1B41\\u1B43\\u1B44\\u1B82\\u1BA1\\u1BA6\\u1BA7\\u1BAA\\u1C24-\\u1C2B\\u1C34\\u1C35\\u1CE1\\u1CF2\\uA823\\uA824\\uA827\\uA880\\uA881\\uA8B4-\\uA8C3\\uA952\\uA953\\uA983\\uA9B4\\uA9B5\\uA9BA\\uA9BB\\uA9BD-\\uA9C0\\uAA2F\\uAA30\\uAA33\\uAA34\\uAA4D\\uAA7B\\uABE3\\uABE4\\uABE6\\uABE7\\uABE9\\uABEA\\uABEC]"),connector_punctuation:new RegExp("[\\u005F\\u203F\\u2040\\u2054\\uFE33\\uFE34\\uFE4D-\\uFE4F\\uFF3F]")};B.prototype.toString=function(){return this.message+" (line: "+this.line+", col: "+this.col+", pos: "+this.pos+")"+"\n\n"+this.stack};var E={},G=Q(["typeof","void","delete","--","++","!","~","-","+"]),H=Q(["--","++"]),I=function(a,b,c){while(c<a.length)b[a[c]]=a[c].substr(0,a[c].length-1),c++;return b}(["+=","-=","/=","*=","%=",">>=","<<=",">>>=","|=","^=","&="],{"=":!0},0),J=function(a,b){for(var c=0,d=1;c<a.length;++c,++d){var e=a[c];for(var f=0;f<e.length;++f)b[e[f]]=d}return b}([["||"],["&&"],["|"],["^"],["&"],["==","===","!=","!=="],["<",">","<=",">=","in","instanceof"],[">>","<<",">>>"],["+","-"],["*","/","%"]],{}),K=Q(["for","do","while","switch"]),L=Q(["atom","num","string","regexp","name"]);M.prototype.toString=function(){return this.name};var V=function(){};c.tokenizer=F,c.parse=N,c.slice=R,c.curry=O,c.member=T,c.array_to_hash=Q,c.PRECEDENCE=J,c.KEYWORDS_ATOM=i,c.RESERVED_WORDS=g,c.KEYWORDS=f,c.ATOMIC_START_TOKEN=L,c.OPERATORS=n,c.is_alphanumeric_char=v,c.set_logger=function(a){V=a}}),require.define("/node_modules/detective/node_modules/burrito/node_modules/uglify-js/lib/process.js",function(a,b,c,d,e){function k(){function a(a){return[this[0],N(a,function(a){var b=[a[0]];return a.length>1&&(b[1]=f(a[1])),b})]}function b(a){var b=[this[0]];return a!=null&&b.push(N(a,f)),b}function f(a){if(a==null)return null;try{e.push(a);var b=a[0],f=d[b];if(f){var g=f.apply(a,a.slice(1));if(g!=null)return g}return f=c[b],f.apply(a,a.slice(1))}finally{e.pop()}}function h(a,b){var c={},e;for(e in a)M(a,e)&&(c[e]=d[e],d[e]=a[e]);var f=b();for(e in c)M(c,e)&&(c[e]?d[e]=c[e]:delete d[e]);return f}var c={string:function(a){return[this[0],a]},num:function(a){return[this[0],a]},name:function(a){return[this[0],a]},toplevel:function(a){return[this[0],N(a,f)]},block:b,splice:b,"var":a,"const":a,"try":function(a,b,c){return[this[0],N(a,f),b!=null?[b[0],N(b[1],f)]:null,c!=null?N(c,f):null]},"throw":function(a){return[this[0],f(a)]},"new":function(a,b){return[this[0],f(a),N(b,f)]},"switch":function(a,b){return[this[0],f(a),N(b,function(a){return[a[0]?f(a[0]):null,N(a[1],f)]})]},"break":function(a){return[this[0],a]},"continue":function(a){return[this[0],a]},conditional:function(a,b,c){return[this[0],f(a),f(b),f(c)]},assign:function(a,b,c){return[this[0],a,f(b),f(c)]},dot:function(a){return[this[0],f(a)].concat(g(arguments,1))},call:function(a,b){return[this[0],f(a),N(b,f)]},"function":function(a,b,c){return[this[0],a,b.slice(),N(c,f)]},defun:function(a,b,c){return[this[0],a,b.slice(),N(c,f)]},"if":function(a,b,c){return[this[0],f(a),f(b),f(c)]},"for":function(a,b,c,d){return[this[0],f(a),f(b),f(c),f(d)]},"for-in":function(a,b,c,d){return[this[0],f(a),f(b),f(c),f(d)]},"while":function(a,b){return[this[0],f(a),f(b)]},"do":function(a,b){return[this[0],f(a),f(b)]},"return":function(a){return[this[0],f(a)]},binary:function(a,b,c){return[this[0],a,f(b),f(c)]},"unary-prefix":function(a,b){return[this[0],a,f(b)]},"unary-postfix":function(a,b){return[this[0],a,f(b)]},sub:function(a,b){return[this[0],f(a),f(b)]},object:function(a){return[this[0],N(a,function(a){return a.length==2?[a[0],f(a[1])]:[a[0],f(a[1]),a[2]]})]},regexp:function(a,b){return[this[0],a,b]},array:function(a){return[this[0],N(a,f)]},stat:function(a){return[this[0],f(a)]},seq:function(){return[this[0]].concat(N(g(arguments),f))},label:function(a,b){return[this[0],a,f(b)]},"with":function(a,b){return[this[0],f(a),f(b)]},atom:function(a){return[this[0],a]}},d={},e=[];return{walk:f,with_walkers:h,parent:function(){return e[e.length-2]},stack:function(){return e}}}function l(a){this.names={},this.mangled={},this.rev_mangled={},this.cname=-1,this.refs={},this.uses_with=!1
,this.uses_eval=!1,this.parent=a,this.children=[],a?(this.level=a.level+1,a.children.push(this)):this.level=0}function n(a){function f(a){b=new l(b);var c=b.body=a();return c.scope=b,b=b.parent,c}function g(a,c){return b.define(a,c)}function h(a){b.refs[a]=!0}function i(a,b,c){var e=this[0]=="defun";return[this[0],e?g(a,"defun"):a,b,f(function(){return e||g(a,"lambda"),N(b,function(a){g(a,"arg")}),N(c,d)})]}function j(a){return function(b){N(b,function(b){g(b[0],a),b[1]&&h(b[0])})}}var b=null,c=k(),d=c.walk,e=[];return f(function(){function k(a,b){for(b=a.children.length;--b>=0;)k(a.children[b]);for(b in a.refs)if(M(a.refs,b))for(var c=a.has(b),d=a;d;d=d.parent){d.refs[b]=c;if(d===c)break}}var f=c.with_walkers({"function":i,defun:i,label:function(a,b){g(a,"label")},"break":function(a){a&&h(a)},"continue":function(a){a&&h(a)},"with":function(a,c){for(var d=b;d;d=d.parent)d.uses_with=!0},"var":j("var"),"const":j("const"),"try":function(a,b,c){if(b!=null)return[this[0],N(a,d),[g(b[0],"catch"),N(b[1],d)],c!=null?N(c,d):null]},name:function(a){a=="eval"&&e.push(b),h(a)}},function(){return d(a)});return N(e,function(a){if(!a.has("eval"))while(a)a.uses_eval=!0,a=a.parent}),k(b),f})}function o(a,b){function f(a,c){return!b.toplevel&&!e.parent?a:b.except&&h(a,b.except)?a:e.get_mangled(a,c)}function g(a){if(b.defines)return!e.has(a)&&M(b.defines,a)?b.defines[a]:null}function i(a,b,c){var g=this[0]=="defun",h;return a&&(g?a=f(a):(h={},!e.uses_eval&&!e.uses_with?a=h[a]=e.next_mangled():h[a]=a)),c=j(c.scope,function(){return b=N(b,function(a){return f(a)}),N(c,d)},h),[this[0],a,b,c]}function j(a,b,c){var d=e;e=a;if(c)for(var g in c)M(c,g)&&a.set_mangle(g,c[g]);for(var g in a.names)M(a.names,g)&&f(g,!0);var h=b();return h.scope=a,e=d,h}function l(a){return[this[0],N(a,function(a){return[f(a[0]),d(a[1])]})]}var c=k(),d=c.walk,e;return b=b||{},c.with_walkers({"function":i,defun:function(){var a=i.apply(this,arguments);switch(c.parent()[0]){case"toplevel":case"function":case"defun":return N.at_top(a)}return a},label:function(a,b){return[this[0],f(a),d(b)]},"break":function(a){if(a)return[this[0],f(a)]},"continue":function(a){if(a)return[this[0],f(a)]},"var":l,"const":l,name:function(a){return g(a)||[this[0],f(a)]},"try":function(a,b,c){return[this[0],N(a,d),b!=null?[f(b[0]),N(b[1],d)]:null,c!=null?N(c,d):null]},toplevel:function(a){var b=this;return j(b.scope,function(){return[b[0],N(a,d)]})}},function(){return d(n(a))})}function q(a,b){return H(a).length>H(b[0]=="stat"?b[1]:b).length?b:a}function r(a){return a[0]=="block"&&a[1]&&a[1].length>0?a[1][a[1].length-1]:a}function s(a){if(a)switch(r(a)[0]){case"return":case"break":case"continue":case"throw":return!0}}function t(a){return a[0]=="unary-prefix"&&h(a[1],["!","delete"])||a[0]=="binary"&&h(a[1],["in","instanceof","==","!=","===","!==","<","<=",">=",">"])||a[0]=="binary"&&h(a[1],["&&","||"])&&t(a[2])&&t(a[3])||a[0]=="conditional"&&t(a[2])&&t(a[3])||a[0]=="assign"&&a[1]===!0&&t(a[3])||a[0]=="seq"&&t(a[a.length-1])}function u(a,b,c){var d=function(){return a[0]=="unary-prefix"&&a[1]=="!"?c?["conditional",a[2],c,b]:["binary","||",a[2],b]:c?["conditional",a,b,c]:["binary","&&",a,b]};return x(a,function(a,d){return y(d?c:b),d?b:c},d)}function v(a){return!a||a[0]=="block"&&(!a[1]||a[1].length==0)}function w(a){return a[0]=="string"||a[0]=="unary-prefix"&&a[1]=="typeof"||a[0]=="binary"&&a[1]=="+"&&(w(a[2])||w(a[3]))}function y(a){v(a)||p("Dropping unreachable code: "+H(a,!0))}function z(a){function d(a){a=N(a,c);for(var b=0;b<a.length;++b){var e=a[b];if(e[0]!="if")continue;if(e[3]&&c(e[3]))continue;var f=c(e[2]);if(!s(f))continue;var g=c(e[1]),h=a.slice(b+1),i=h.length==1?h[0]:["block",h],j=a.slice(0,b).concat([[e[0],g,f,i]]);return d(j)}return a}function e(a,b,c){return c=d(c),[this[0],a,b,c]}function f(a){return[this[0],a!=null?d(a):null]}var b=k(),c=b.walk;return b.with_walkers({defun:e,"function":e,block:f,splice:f,toplevel:function(a){return[this[0],d(a)]},"try":function(a,b,c){return[this[0],d(a),b!=null?[b[0],d(b[1])]:null,c!=null?d(c):null]}},function(){return c(a)})}function A(a,b){function g(){throw e}function h(){throw f}function i(){return b.call(this,this,c,g,h)}function j(a){if(a=="++"||a=="--")return i.apply(this,arguments)}var c=k(),d=c.walk,e={},f={};return c.with_walkers({"try":i,"throw":i,"return":i,"new":i,"switch":i,"break":i,"continue":i,assign:i,call:i,"if":i,"for":i,"for-in":i,"while":i,"do":i,"return":i,"unary-prefix":j,"unary-postfix":j,defun:i},function(){for(;;)try{d(a);break}catch(b){if(b===e)break;if(b===f)continue;throw b}})}function B(a){function e(a,b){var e=d;d=b,a=N(a,c);var f={},g=N(b.names,function(a,c){return a!="var"?N.skip:b.references(c)?(f[c]=!0,[c]):N.skip});return g.length>0&&(A(["block",a],function(a,b,c,d){if(a[0]=="assign"&&a[1]===!0&&a[2][0]=="name"&&M(f,a[2][1])){for(var e=g.length;--e>=0;)if(g[e][0]==a[2][1]){g[e][1]&&c(),g[e][1]=a[3],g.push(g.splice(e,1)[0]);break}var h=b.parent();if(h[0]=="seq"){var i=h[2];i.unshift(0,h.length),h.splice.apply(h,i)}else h[0]=="stat"?h.splice(0,h.length,"block"):c();d()}c()}),a.unshift(["var",g])),d=e,a}function f(a){var c=null;for(var d=a.length;--d>=0;){var e=a[d];if(!e[1])continue;e=["assign",!0,["name",e[0]],e[1]],c==null?c=e:c=["seq",e,c]}return c==null?b.parent()[0]=="for-in"?["name",a[0][0]]:N.skip:["stat",c]}function g(a){return[this[0],e(a,this.scope)]}var b=k(),c=b.walk,d;return b.with_walkers({"function":function(a,b,c){for(var d=b.length;--d>=0&&!c.scope.references(b[d]);)b.pop();return c.scope.references(a)||(a=null),[this[0],a,b,e(c,c.scope)]},defun:function(a,b,c){if(!d.references(a))return N.skip;for(var f=b.length;--f>=0&&!c.scope.references(b[f]);)b.pop();return[this[0],a,b,e(c,c.scope)]},"var":f,toplevel:g},function(){return c(n(a))})}function C(a,b){function f(a){var c=["unary-prefix","!",a];switch(a[0]){case"unary-prefix":return a[1]=="!"&&t(a[2])?a[2]:c;case"seq":return a=g(a),a[a.length-1]=f(a[a.length-1]),a;case"conditional":return q(c,["conditional",a[1],f(a[2]),f(a[3])]);case"binary":var d=a[1],e=a[2],h=a[3];if(!b.keep_comps)switch(d){case"<=":return["binary",">",e,h];case"<":return["binary",">=",e,h];case">=":return["binary","<",e,h];case">":return["binary","<=",e,h]}switch(d){case"==":return["binary","!=",e,h];case"!=":return["binary","==",e,h];case"===":return["binary","!==",e,h];case"!==":return["binary","===",e,h];case"&&":return q(c,["binary","||",f(e),f(h)]);case"||":return q(c,["binary","&&",f(e),f(h)])}}return c}function i(a,b){var c=e;e=a;var d=b();return d.scope=a,e=c,d}function j(a){return a!=null&&a[0]=="block"&&a[1]&&(a[1].length==1?a=a[1][0]:a[1].length==0&&(a=["block"])),a}function l(a,b,c){var d=this[0]=="defun";return c=i(c.scope,function(){var b=m(c,"lambda");return!d&&a&&!e.references(a)&&(a=null),b}),[this[0],a,b,c]}function m(a,c){return a=N(a,d),a=a.reduce(function(a,b){return b[0]=="block"?b[1]&&a.push.apply(a,b[1]):a.push(b),a},[]),a=function(b,c){return a.forEach(function(a){c&&(a[0]=="var"&&c[0]=="var"||a[0]=="const"&&c[0]=="const")?c[1]=c[1].concat(a[1]):(b.push(a),c=a)}),b}([]),b.dead_code&&(a=function(c,d){return a.forEach(function(a){d?a[0]=="function"||a[0]=="defun"?c.push(a):a[0]=="var"||a[0]=="const"?(b.no_warnings||p("Variables declared in unreachable code"),a[1]=N(a[1],function(a){return a[1]&&!b.no_warnings&&y(["assign",!0,["name",a[0]],a[1]]),[a[0]]}),c.push(a)):b.no_warnings||y(a):(c.push(a),h(a[0],["return","throw","break","continue"])&&(d=!0))}),c}([])),b.make_seqs&&(a=function(b,c){return a.forEach(function(a){c&&c[0]=="stat"&&a[0]=="stat"?c[1]=["seq",c[1],a[1]]:(b.push(a),c=a)}),b.length>=2&&b[b.length-2][0]=="stat"&&(b[b.length-1][0]=="return"||b[b.length-1][0]=="throw")&&b[b.length-1][1]&&b.splice(b.length-2,2,[b[b.length-1][0],["seq",b[b.length-2][1],b[b.length-1][1]]]),b}([])),a}function o(a,b,c){return x(a,function(a,d){return d?(y(c),b):(y(b),c)},function(){return r(a,b,c)})}function r(a,b,c){a=d(a),b=d(b),c=d(c),v(b)?(a=f(a),b=c,c=null):v(c)?c=null:function(){var d=H(a),e=f(a),g=H(e);if(g.length<d.length){var h=b;b=c,c=h,a=e}}();if(v(c)&&v(b))return["stat",a];var e=["if",a,b,c];return b[0]=="if"&&v(b[3])&&v(c)?e=q(e,d(["if",["binary","&&",a,b[1]],b[2]])):b[0]=="stat"?c?c[0]=="stat"&&(e=q(e,["stat",u(a,b[1],c[1])])):e=q(e,["stat",u(a,b[1])]):c&&b[0]==c[0]&&(b[0]=="return"||b[0]=="throw")&&b[1]&&c[1]?e=q(e,[b[0],u(a,b[1],c[1])]):c&&s(b)?(e=[["if",a,b]],c[0]=="block"?c[1]&&(e=e.concat(c[1])):e.push(c),e=d(["block",e])):b&&s(c)&&(e=[["if",f(a),c]],b[0]=="block"?b[1]&&(e=e.concat(b[1])):e.push(b),e=d(["block",e])),e}function w(a,b){return x(a,function(a,c){return c?["for",null,null,null,d(b)]:(y(b),["block"])})}b=K(b,{make_seqs:!0,dead_code:!0,keep_comps:!0,no_warnings:!1});var c=k(),d=c.walk,e;return c.with_walkers({sub:function(a,b){if(b[0]=="string"){var c=b[1];if(L(c))return["dot",d(a),c];if(/^[1-9][0-9]*$/.test(c)||c==="0")return["sub",d(a),["num",parseInt(c,10)]]}},"if":o,toplevel:function(a){return["toplevel",i(this.scope,function(){return m(a)})]},"switch":function(a,b){var c=b.length-1;return["switch",d(a),N(b,function(a,b){var e=m(a[1]);if(b==c&&e.length>0){var f=e[e.length-1];f[0]=="break"&&!f[1]&&e.pop()}return[a[0]?d(a[0]):null,e]})]},"function":l,defun:l,block:function(a){if(a)return j(["block",m(a)])},binary:function(a,b,c){return x(["binary",a,d(b),d(c)],function(b){return q(d(b),this)},function(){return this})},conditional:function(a,b,c){return u(d(a),d(b),d(c))},"try":function(a,b,c){return["try",m(a),b!=null?[b[0],m(b[1])]:null,c!=null?m(c):null]},"unary-prefix":function(a,b){b=d(b);var c=["unary-prefix",a,b];return a=="!"&&(c=q(c,f(b))),x(c,function(a,b){return d(a)},function(){return c})},name:function(a){switch(a){case"true":return["unary-prefix","!",["num",0]];case"false":return["unary-prefix","!",["num",1]]}},"while":w},function(){for(var b=0;b<2;++b)a=z(a),a=n(a),a=d(a);return a})}function E(a,b){var c=0,d=0;return a=a.replace(/[\\\b\f\n\r\t\x22\x27\u2028\u2029]/g,function(a){switch(a){case"\\":return"\\\\";case"\b":return"\\b";case"\f":return"\\f";case"\n":return"\\n";case"\r":return"\\r";case"\t":return"\\t";case"\u2028":return"\\u2028";case"\u2029":return"\\u2029";case'"':return++c,'"';case"'":return++d,"'"}return a}),b&&(a=F(a)),c>d?"'"+a.replace(/\x27/g,"\\'")+"'":'"'+a.replace(/\x22/g,'\\"')+'"'}function F(a){return a.replace(/[\u0080-\uffff]/g,function(a){var b=a.charCodeAt(0).toString(16);while(b.length<4)b="0"+b;return"\\u"+b})}function H(a,b){function m(a){var c=E(a,b.ascii_only);return b.inline_script&&(c=c.replace(/<\x2fscript([>/\t\n\f\r ])/gi,"<\\/script$1")),c}function n(a){return a=a.toString(),b.ascii_only&&(a=F(a)),a}function o(a){return a==null&&(a=""),c&&(a=J(" ",b.indent_start+d*b.indent_level)+a),a}function p(a,b){b==null&&(b=1),d+=b;try{return a.apply(null,g(arguments,1))}finally{d-=b}}function q(a){if(c)return a.join(" ");var b=[];for(var d=0;d<a.length;++d){var e=a[d+1];b.push(a[d]),e&&(/[a-z0-9_\x24]$/i.test(a[d].toString())&&/^[a-z0-9_\x24]/i.test(e.toString())||/[\+\-]$/.test(a[d].toString())&&/^[\+\-]/.test(e.toString()))&&b.push(" ")}return b.join("")}function r(a){return a.join(","+l)}function s(a){var b=y(a);for(var c=1;c<arguments.length;++c){var d=arguments[c];if(d instanceof Function&&d(a)||a[0]==d)return"("+b+")"}return b}function t(a){if(a.length==1)return a[0];if(a.length==2){var b=a[1];return a=a[0],a.length<=b.length?a:b}return t([a[0],t(a.slice(1))])}function u(a){if(a[0]=="function"||a[0]=="object"){var b=g(x.stack()),c=b.pop(),d=b.pop();while(d){if(d[0]=="stat")return!0;if((d[0]!="seq"&&d[0]!="call"&&d[0]!="dot"&&d[0]!="sub"&&d[0]!="conditional"||d[1]!==c)&&(d[0]!="binary"&&d[0]!="assign"&&d[0]!="unary-postfix"||d[2]!==c))return!1;c=d,d=b.pop()}}return!M(D,a[0])}function w(a){var b=a.toString(10),c=[b.replace(/^0\./,".")],d;return Math.floor(a)===a?(c.push("0x"+a.toString(16).toLowerCase(),"0"+a.toString(8)),(d=/^(.*?)(0+)$/.exec(a))&&c.push(d[1]+"e"+d[2].length)):(d=/^0?\.(0+)(.*)$/.exec(a))&&c.push(d[2]+"e-"+(d[1].length+d[2].length),b.substr(b.indexOf("."))),t(c)}function z(a){if(a[0]=="do")return I([a]);var b=a;for(;;){var c=b[0];if(c=="if"){if(!b[3])return y(["block",[a]]);b=b[3]}else if(c=="while"||c=="do")b=b[2];else{if(c!="for"&&c!="for-in")break;b=b[4]}}return y(a)}function A(a,b,c,d){var e=d||"function";return a&&(e+=" "+n(a)),e+="("+r(N(b,n))+")",q([e,I(c)])}function B(a){switch(a[0]){case"with":case"while":return v(a[2]);case"for":case"for-in":return v(a[4]);case"if":if(v(a[2])&&!a[3])return!0;if(a[3])return v(a[3])?!0:B(a[3]);return B(a[2])}}function C(a,b){for(var d=[],e=a.length-1,f=0;f<=e;++f){var g=a[f],h=y(g);h!=";"&&(!c&&f==e&&!B(g)&&(h=h.replace(/;+\s*$/,"")),d.push(h))}return b?d:N(d,o)}function H(a){var b=a.length;return b==0?"{}":"{"+e+N(a,function(a,d){var f=a[1].length>0,g=p(function(){return o(a[0]?q(["case",y(a[0])+":"]):"default:")},.5)+(f?e+p(function(){return C(a[1]).join(e)}):"");return!c&&f&&d<b-1&&(g+=";"),g}).join(e)+e+o("}")}function I(a){return a?a.length==0?"{}":"{"+e+p(function(){return C(a).join(e)})+e+o("}"):";"}function O(a){var b=a[0],c=a[1];return c!=null&&(b=q([n(b),"=",s(c,"seq")])),b}b=K(b,{indent_start:0,indent_level:4,quote_keys:!1,space_colon:!1,beautify:!1,ascii_only:!1,inline_script:!1});var c=!!b.beautify,d=0,e=c?"\n":"",l=c?" ":"",x=k(),y=x.walk;return x.with_walkers({string:m,num:w,name:n,toplevel:function(a){return C(a).join(e+e)},splice:function(a){var b=x.parent();return M(G,b)?I.apply(this,arguments):N(C(a,!0),function(a,b){return b>0?o(a):a}).join(e)},block:I,"var":function(a){return"var "+r(N(a,O))+";"},"const":function(a){return"const "+r(N(a,O))+";"},"try":function(a,b,c){var d=["try",I(a)];return b&&d.push("catch","("+b[0]+")",I(b[1])),c&&d.push("finally",I(c)),q(d)},"throw":function(a){return q(["throw",y(a)])+";"},"new":function(a,b){return b=b.length>0?"("+r(N(b,y))+")":"",q(["new",s(a,"seq","binary","conditional","assign",function(a){var b=k(),c={};try{b.with_walkers({call:function(){throw c},"function":function(){return this}},function(){b.walk(a)})}catch(d){if(d===c)return!0;throw d}})+b])},"switch":function(a,b){return q(["switch","("+y(a)+")",H(b)])},"break":function(a){var b="break";return a!=null&&(b+=" "+n(a)),b+";"},"continue":function(a){var b="continue";return a!=null&&(b+=" "+n(a)),b+";"},conditional:function(a,b,c){return q([s(a,"assign","seq","conditional"),"?",s(b,"seq"),":",s(c,"seq")])},assign:function(a,b,c){return a&&a!==!0?a+="=":a="=",q([y(b),a,s(c,"seq")])},dot:function(a){var b=y(a),c=1;a[0]=="num"?/\./.test(a[1])||(b+="."):u(a)&&(b="("+b+")");while(c<arguments.length)b+="."+n(arguments[c++]);return b},call:function(a,b){var c=y(a);return u(a)&&(c="("+c+")"),c+"("+r(N(b,function(a){return s(a,"seq")}))+")"},"function":A,defun:A,"if":function(a,b,c){var d=["if","("+y(a)+")",c?z(b):y(b)];return c&&d.push("else",y(c)),q(d)},"for":function(a,b,c,d){var e=["for"];a=(a!=null?y(a):"").replace(/;*\s*$/,";"+l),b=(b!=null?y(b):"").replace(/;*\s*$/,";"+l),c=(c!=null?y(c):"").replace(/;*\s*$/,"");var f=a+b+c;return f=="; ; "&&(f=";;"),e.push("("+f+")",y(d)),q(e)},"for-in":function(a,b,c,d){return q(["for","("+(a?y(a).replace(/;+$/,""):y(b)),"in",y(c)+")",y(d)])},"while":function(a,b){return q(["while","("+y(a)+")",y(b)])},"do":function(a,b){return q(["do",y(b),"while","("+y(a)+")"])+";"},"return":function(a){var b=["return"];return a!=null&&b.push(y(a)),q(b)+";"},binary:function(a,d,e){var f=y(d),g=y(e);if(h(d[0],["assign","conditional","seq"])||d[0]=="binary"&&i[a]>i[d[1]])f="("+f+")";return h(e[0],["assign","conditional","seq"])||e[0]=="binary"&&i[a]>=i[e[1]]&&(e[1]!=a||!h(a,["&&","||","*"]))?g="("+g+")":!c&&b.inline_script&&(a=="<"||a=="<<")&&e[0]=="regexp"&&/^script/i.test(e[1])&&(g=" "+g),q([f,a,g])},"unary-prefix":function(a,b){var c=y(b);return b[0]=="num"||b[0]=="unary-prefix"&&!M(j,a+b[1])||!u(b)||(c="("+c+")"),a+(f.is_alphanumeric_char(a.charAt(0))?" ":"")+c},"unary-postfix":function(a,b){var c=y(b);return b[0]=="num"||b[0]=="unary-postfix"&&!M(j,a+b[1])||!u(b)||(c="("+c+")"),c+a},sub:function(a,b){var c=y(a);return u(a)&&(c="("+c+")"),c+"["+y(b)+"]"},object:function(a){return a.length==0?"{}":"{"+e+p(function(){return N(a,function(a){if(a.length==3)return o(A(a[0],a[1][2],a[1][3],a[2]));var d=a[0],e=s(a[1],"seq");return b.quote_keys?d=m(d):(typeof d=="number"||!c&&+d+""==d)&&parseFloat(d)>=0?d=w(+d):L(d)||(d=m(d)),o(q(c&&b.space_colon?[d,":",e]:[d+":",e]))}).join(","+e)})+e+o("}")},regexp:function(a,b){return"/"+a+"/"+b},array:function(a){return a.length==0?"[]":q(["[",r(N(a,function(a){return!c&&a[0]=="atom"&&a[1]=="undefined"?"":s(a,"seq")})),"]"])},stat:function(a){return y(a).replace(/;*\s*$/,";")},seq:function(){return r(N(g(arguments),y))},label:function(a,b){return q([n(a),":",y(b)])},"with":function(a,b){return q(["with","("+y(a)+")",y(b)])},atom:function(a){return n(a)}},function(){return y(a)})}function I(a,b){var c=[0];return f.parse(function(){function h(a){return a.pos-e}function i(a){e=a.pos,c.push(e)}function j(){var a=d.apply(this,arguments);a:{if(g&&g.type=="keyword")break a;if(h(a)>b)switch(a.type){case"keyword":case"atom":case"name":case"punc":i(a);break a}}return g=a,a}var d=f.tokenizer(a),e=0,g;return j.context=function(){return d.context.apply(this,arguments)},j}()),c.map(function(b,d){return a.substring(b,c[d+1]||a.length)}).join("\n")}function J(a,b){if(b<=0)return"";if(b==1)return a;var c=J(a,b>>1);return c+=c,b&1&&(c+=a),c}function K(a,b){var c={};a===!0&&(a={});for(var d in b)M(b,d)&&(c[d]=a&&M(a,d)?a[d]:b[d]);return c}function L(a){return/^[a-z_$][a-z0-9_$]*$/i.test(a)&&a!="this"&&!M(f.KEYWORDS_ATOM,a)&&!M(f.RESERVED_WORDS,a)&&!M(f.KEYWORDS,a)}function M(a,b){return Object.prototype.hasOwnProperty.call(a,b)}var f=a("./parse-js"),g=f.slice,h=f.member,i=f.PRECEDENCE,j=f.OPERATORS,m=function(){var a="abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ$_";return function(b){var c="";do c=a.charAt(b%54)+c,b=Math.floor(b/54);while(b>0);return c}}();l.prototype={has:function(a){for(var b=this;b;b=b.parent)if(M(b.names,a))return b},has_mangled:function(a){for(var b=this;b;b=b.parent)if(M(b.rev_mangled,a))return b},toJSON:function(){return{names:this.names,uses_eval:this.uses_eval,uses_with:this.uses_with}},next_mangled:function(){for(;;){var a=m(++this.cname),b;b=this.has_mangled(a);if(b&&this.refs[b.rev_mangled[a]]===b)continue;b=this.has(a);if(b&&b!==this&&this.refs[a]===b&&!b.has_mangled(a))continue;if(M(this.refs,a)&&this.refs[a]==null)continue;if(!L(a))continue;return a}},set_mangle:function(a,b){return this.rev_mangled[b]=a,this.mangled[a]=b},get_mangled:function(a,b){if(this.uses_eval||this.uses_with)return a;var c=this.has(a);return c?M(c.mangled,a)?c.mangled[a]:b?c.set_mangle(a,c.next_mangled()):a:a},references:function(a){return a&&!this.parent||this.uses_with||this.uses_eval||this.refs[a]},define:function(a,b){if(a!=null){if(b=="var"||!M(this.names,a))this.names[a]=b||"var";return a}}};var p=function(){},x=function(){function b(c){switch(c[0]){case"string":case"num":return c[1];case"name":case"atom":switch(c[1]){case"true":return!0;case"false":return!1}break;case"unary-prefix":switch(c[1]){case"!":return!b(c[2]);case"typeof":return typeof b(c[2]);case"~":return~b(c[2]);case"-":return-b(c[2]);case"+":return+b(c[2])}break;case"binary":var d=c[2],e=c[3];switch(c[1]){case"&&":return b(d)&&b(e);case"||":return b(d)||b(e);case"|":return b(d)|b(e);case"&":return b(d)&b(e);case"^":return b(d)^b(e);case"+":return b(d)+b(e);case"*":return b(d)*b(e);case"/":return b(d)/b(e);case"-":return b(d)-b(e);case"<<":return b(d)<<b(e);case">>":return b(d)>>b(e);case">>>":return b(d)>>>b(e);case"==":return b(d)==b(e);case"===":return b(d)===b(e);case"!=":return b(d)!=b(e);case"!==":return b(d)!==b(e);case"<":return b(d)<b(e);case"<=":return b(d)<=b(e);case">":return b(d)>b(e);case">=":return b(d)>=b(e);case"in":return b(d)in b(e);case"instanceof":return b(d)instanceof b(e)}}throw a}var a={};return function(c,d,e){try{var f=b(c),g;switch(typeof f){case"string":g=["string",f];break;case"number":g=["num",f];break;case"boolean":g=["name",String(f)];break;default:throw new Error("Can't handle constant of type: "+typeof f)}return d.call(c,g,f)}catch(h){if(h===a){if(c[0]!="binary"||c[1]!="==="&&c[1]!="!=="||!(w(c[2])&&w(c[3])||t(c[2])&&t(c[3]))){if(e&&c[0]=="binary"&&(c[1]=="||"||c[1]=="&&"))try{var i=b(c[2]);c=c[1]=="&&"&&(i?c[3]:i)||c[1]=="||"&&(i?i:c[3])||c}catch(j){}}else c[1]=c[1].substr(0,2);return e?e.call(c,c):null}throw h}}}(),D=f.array_to_hash(["name","array","object","string","dot","sub","call","regexp"]),G=f.array_to_hash(["if","while","do","for","for-in","with"]),N;(function(){function b(a){this.v=a}function c(a){this.v=a}N=function(d,e,f){function j(){var j=e.call(f,d[i],i);j instanceof b?(j=j.v,j instanceof c?h.push.apply(h,j.v):h.push(j)):j!=a&&(j instanceof c?g.push.apply(g,j.v):g.push(j))}var g=[],h=[],i;if(d instanceof Array)for(i=0;i<d.length;++i)j();else for(i in d)M(d,i)&&j();return h.concat(g)},N.at_top=function(a){return new b(a)},N.splice=function(a){return new c(a)};var a=N.skip={}})(),c.ast_walker=k,c.ast_mangle=o,c.ast_squeeze=C,c.ast_lift_variables=B,c.gen_code=H,c.ast_add_scope=n,c.set_logger=function(a){p=a},c.make_string=E,c.split_lines=I,c.MAP=N,c.ast_squeeze_more=a("./squeeze-more").ast_squeeze_more}),require.define("/node_modules/detective/node_modules/burrito/node_modules/uglify-js/lib/squeeze-more.js",function(a,b,c,d,e){function n(a){function e(a,b){var c=d,e;return d=a,e=b(),d=c,e}function f(a,b,d){return[this[0],a,b,e(d.scope,j(k,d,c))]}var b=g.ast_walker(),c=b.walk,d;return b.with_walkers({toplevel:function(a){return[this[0],e(this.scope,j(k,a,c))]},"function":f,defun:f,"new":function(a,b){if(a[0]=="name"&&a[1]=="Array"&&!d.has("Array"))return b.length!=1?["array",b]:c(["call",["name","Array"],b])},call:function(a,b){if(a[0]=="dot"&&a[2]=="toString"&&b.length==0)return["binary","+",a[1],["string",""]];if(a[0]=="name"&&a[1]=="Array"&&b.length!=1&&!d.has("Array"))return["array",b]}},function(){return c(g.ast_add_scope(a))})}var f=a("./parse-js"),g=a("./process"),h=f.slice,i=f.member,j=f.curry,k=g.MAP,l=f.PRECEDENCE,m=f.OPERATORS;c.ast_squeeze_more=n}),require.define("/node_modules/detective/node_modules/burrito/node_modules/traverse/package.json",function(a,b,c,d,e){b.exports={main:"./index"}}),require.define("/node_modules/detective/node_modules/burrito/node_modules/traverse/index.js",function(a,b,c,d,e){function f(a){if(!(this instanceof f))return new f(a);this.value=a}function g(a,b,c){var d=[],e=[],f=!0;return function g(a){var l=c?h(a):a,m={},n=!0,o={node:l,node_:a,path:[].concat(d),parent:e[e.length-1],parents:e,key:d.slice(-1)[0],isRoot:d.length===0,level:d.length,circular:null,update:function(a,b){o.isRoot||(o.parent.node[o.key]=a),o.node=a,b&&(n=!1)},"delete":function(a){delete o.parent.node[o.key],a&&(n=!1)},remove:function(a){j(o.parent.node)?o.parent.node.splice(o.key,1):delete o.parent.node[o.key],a&&(n=!1)},keys:null,before:function(a){m.before=a},after:function(a){m.after=a},pre:function(a){m.pre=a},post:function(a){m.post=a},stop:function(){f=!1},block:function(){n=!1}};if(!f)return o;if(typeof l=="object"&&l!==null){o.keys=i(l),o.isLeaf=o.keys.length==0;for(var p=0;p<e.length;p++)if(e[p].node_===a){o.circular=e[p];break}}else o.isLeaf=!0;o.notLeaf=!o.isLeaf,o.notRoot=!o.isRoot;var q=b.call(o,o.node);return q!==undefined&&o.update&&o.update(q),m.before&&m.before.call(o,o.node),n?(typeof o.node=="object"&&o.node!==null&&!o.circular&&(e.push(o),k(o.keys,function(a,b){d.push(a),m.pre&&m.pre.call(o,o.node[a],a);var e=g(o.node[a]);c&&Object.hasOwnProperty.call(o.node,a)&&(o.node[a]=e.node),e.isLast=b==o.keys.length-1,e.isFirst=b==0,m.post&&m.post.call(o,e),d.pop()}),e.pop()),m.after&&m.after.call(o,o.node),o):o}(a).node}function h(a){if(typeof a=="object"&&a!==null){var b;if(j(a))b=[];else if(a instanceof Date)b=new Date(a);else if(a instanceof Boolean)b=new Boolean(a);else if(a instanceof Number)b=new Number(a);else if(a instanceof String)b=new String(a);else if(Object.create&&Object.getPrototypeOf)b=Object.create(Object.getPrototypeOf(a));else if(a.__proto__||a.constructor.prototype){var c=a.__proto__||a.constructor.prototype||{},d=function(){};d.prototype=c,b=new d,b.__proto__||(b.__proto__=c)}return k(i(a),function(c){b[c]=a[c]}),b}return a}b.exports=f,f.prototype.get=function(a){var b=this.value;for(var c=0;c<a.length;c++){var d=a[c];if(!Object.hasOwnProperty.call(b,d)){b=undefined;break}b=b[d]}return b},f.prototype.set=function(a,b){var c=this.value;for(var d=0;d<a.length-1;d++){var e=a[d];Object.hasOwnProperty.call(c,e)||(c[e]={}),c=c[e]}return c[a[d]]=b,b},f.prototype.map=function(a){return g(this.value,a,!0)},f.prototype.forEach=function(a){return this.value=g(this.value,a,!1),this.value},f.prototype.reduce=function(a,b){var c=arguments.length===1,d=c?this.value:b;return this.forEach(function(b){if(!this.isRoot||!c)d=a.call(this,d,b)}),d},f.prototype.paths=function(){var a=[];return this.forEach(function(b){a.push(this.path)}),a},f.prototype.nodes=function(){var a=[];return this.forEach(function(b){a.push(this.node)}),a},f.prototype.clone=function(){var a=[],b=[];return function c(d){for(var e=0;e<a.length;e++)if(a[e]===d)return b[e];if(typeof d=="object"&&d!==null){var f=h(d);return a.push(d),b.push(f),k(i(d),function(a){f[a]=c(d[a])}),a.pop(),b.pop(),f}return d}(this.value)};var i=Object.keys||function(b){var c=[];for(var d in b)c.push(d);return c},j=Array.isArray||function(b){return Object.prototype.toString.call(b)==="[object Array]"},k=function(a,b){if(a.forEach)return a.forEach(b);for(var c=0;c<a.length;c++)b(a[c],c,a)};k(i(f.prototype),function(a){f[a]=function(b){var c=[].slice.call(arguments,1),d=f(b);return d[a].apply(d,c)}})}),require.define("vm",function(require,module,exports,__dirname,__filename){var Object_keys=function(a){if(Object.keys)return Object.keys(a);var b=[];for(var c in a)b.push(c);return b},forEach=function(a,b){if(a.forEach)return a.forEach(b);for(var c=0;c<a.length;c++)b(a[c],c,a)},Script=exports.Script=function(b){if(!(this instanceof Script))return new Script(b);this.code=b},iframe=document.createElement("iframe");iframe.style||(iframe.style={}),iframe.style.display="none";var iframeCapable=!0;if(navigator.appName==="Microsoft Internet Explorer"){var m=navigator.appVersion.match(/\bMSIE (\d+\.\d+);/);m&&parseFloat(m[1])<=9&&(iframeCapable=!1)}Script.prototype.runInNewContext=function(a){a||(a={});if(!iframeCapable){var b=Object_keys(a),c=[];for(var d=0;d<b.length;d++)c.push(a[b[d]]);var e=new Function(b,"return "+this.code);return e.apply(null,c)}document.body.appendChild(iframe);var f=iframe.contentWindow||window.frames&&window.frames[window.frames.length-1]||window[window.length-1];forEach(Object_keys(a),function(b){f[b]=a[b],iframe[b]=a[b]});if(f.eval)var g=f.eval(this.code);else{iframe.setAttribute("src","javascript:__browserifyVmResult=("+this.code+")");if("__browserifyVmResult"in f)var g=f.__browserifyVmResult;else iframeCapable=!1,g=this.runInThisContext(a)}return forEach(Object_keys(f),function(b){a[b]=f[b]}),document.body.removeChild(iframe),g},Script.prototype.runInThisContext=function(){return eval(this.code)},Script.prototype.runInContext=function(a){return this.runInNewContext(a)},forEach(Object_keys(Script.prototype),function(a){exports[a]=Script[a]=function(b){var c=Script(b);return c[a].apply(c,[].slice.call(arguments,1))}}),exports.createScript=function(a){return exports.Script(a)},exports.createContext=Script.createContext=function(a){var b={};return forEach(Object_keys(a),function(c){b[c]=a[c]}),b}}),require.define("/node_modules/http-browserify/package.json",function(a,b,c,d,e){b.exports={main:"index.js",browserify:"browser.js"}}),require.define("/node_modules/http-browserify/browser.js",function(a,b,c,d,e){var f=b.exports,g=a("events").EventEmitter,h=a("./lib/request");f.request=function(a,b){a||(a={}),a.host||(a.host=window.location.host.split(":")[0]),a.port||(a.port=window.location.port);var c=new h(new i,a);return b&&c.on("response",b),c},f.get=function(a,b){a.method="GET";var c=f.request(a,b);return c.end(),c};var i=function(){if(typeof window=="undefined")throw new Error("no window object present");if(window.XMLHttpRequest)return window.XMLHttpRequest;if(window.ActiveXObject){var a=["Msxml2.XMLHTTP.6.0","Msxml2.XMLHTTP.3.0","Microsoft.XMLHTTP"];for(var b=0;b<a.length;b++)try{var c=new window.ActiveXObject(a[b]);return function(){if(c){var d=c;return c=null,d}return new window.ActiveXObject(a[b])}}catch(d){}throw new Error("ajax not supported in this browser")}throw new Error("ajax not supported in this browser")}()}),require.define("events",function(a,b,c,d,e){process.EventEmitter||(process.EventEmitter=function(){});var f=c.EventEmitter=process.EventEmitter,g=typeof Array.isArray=="function"?Array.isArray:function(a){return Object.toString.call(a)==="[object Array]"},h=10;f.prototype.setMaxListeners=function(a){this._events||(this._events={}),this._events.maxListeners=a},f.prototype.emit=function(a){if(a==="error")if(!this._events||!this._events.error||g(this._events.error)&&!this._events.error.length)throw arguments[1]instanceof Error?arguments[1]:new Error("Uncaught, unspecified 'error' event.");if(!this._events)return!1;var b=this._events[a];if(!b)return!1;if(typeof b=="function"){switch(arguments.length){case 1:b.call(this);break;case 2:b.call(this,arguments[1]);break;case 3:b.call(this,arguments[1],arguments[2]);break;default:var c=Array.prototype.slice.call(arguments,1);b.apply(this,c)}return!0}if(g(b)){var c=Array.prototype.slice.call(arguments,1),d=b.slice();for(var e=0,f=d.length;e<f;e++)d[e].apply(this,c);return!0}return!1},f.prototype.addListener=function(a,b){if("function"!=typeof b)throw new Error("addListener only takes instances of Function");this._events||(this._events={}),this.emit("newListener",a,b);if(!this._events[a])this._events[a]=b;else if(g(this._events[a])){if(!this._events[a].warned){var c;this._events.maxListeners!==undefined?c=this._events.maxListeners:c=h,c&&c>0&&this._events[a].length>c&&(this._events[a].warned=!0,console.error("(node) warning: possible EventEmitter memory leak detected. NaN listeners added. Use emitter.setMaxListeners() to increase limit.",this._events[a].length),console.trace())}this._events[a].push(b)}else this._events[a]=[this._events[a],b];return this},f.prototype.on=f.prototype.addListener,f.prototype.once=function(a,b){var c=this;return c.on(a,function d(){c.removeListener(a,d),b.apply(this,arguments)}),this},f.prototype.removeListener=function(a,b){if("function"!=typeof b)throw new Error("removeListener only takes instances of Function");if(!this._events||!this._events[a])return this;var c=this._events[a];if(g(c)){var d=c.indexOf(b);if(d<0)return this;c.splice(d,1),c.length==0&&delete this._events[a]}else this._events[a]===b&&delete this._events[a];return this},f.prototype.removeAllListeners=function(a){return a&&this._events&&this._events[a]&&(this._events[a]=null),this},f.prototype.listeners=function(a){return this._events||(this._events={}),this._events[a]||(this._events[a]=[]),g(this._events[a])||(this._events[a]=[this._events[a]]),this._events[a]}}),require.define("/node_modules/http-browserify/lib/request.js",function(a,b,c,d,e){var f=a("events").EventEmitter,g=a("./response"),h=b.exports=function(a,b){var c=this;c.xhr=a,c.body="";var d=b.host+":"+b.port+(b.path||"/");a.open(b.method||"GET",(b.scheme||"http")+"://"+d,!0),b.headers&&Object.keys(b.headers).forEach(function(d){if(!c.isSafeRequestHeader(d))return;var e=b.headers[d];Array.isArray(e)?e.forEach(function(b){a.setRequestHeader(d,b)}):a.setRequestHeader(d,e)});var e=new g;e.on("ready",function(){c.emit("response",e)}),a.onreadystatechange=function(){e.handle(a)}};h.prototype=new f,h.prototype.setHeader=function(a,b){if(Array.isArray&&Array.isArray(b)||b instanceof Array)for(var c=0;c<b.length;c++)this.xhr.setRequestHeader(a,b[c]);else this.xhr.setRequestHeader(a,b)},h.prototype.write=function(a){this.body+=a},h.prototype.end=function(a){a!==undefined&&this.write(a),this.xhr.send(this.body)},h.unsafeHeaders=["accept-charset","accept-encoding","access-control-request-headers","access-control-request-method","connection","content-length","cookie","cookie2","content-transfer-encoding","date","expect","host","keep-alive","origin","referer","te","trailer","transfer-encoding","upgrade","user-agent","via"],h.prototype.isSafeRequestHeader=function(a){return a?h.unsafeHeaders.indexOf(a.toLowerCase())===-1:!1}}),require.define("/node_modules/http-browserify/lib/response.js",function(a,b,c,d,e){function i(a){var b=a.getAllResponseHeaders().split(/\r?\n/),c={};for(var d=0;d<b.length;d++){var e=b[d];if(e==="")continue;var f=e.match(/^([^:]+):\s*(.*)/);if(f){var g=f[1].toLowerCase
-(),h=f[2];c[g]!==undefined?Array.isArray&&Array.isArray(c[g])||c[g]instanceof Array?c[g].push(h):c[g]=[c[g],h]:c[g]=h}else c[e]=!0}return c}var f=a("events").EventEmitter,g=b.exports=function(a){this.offset=0};g.prototype=new f;var h={streaming:!0,status2:!0};g.prototype.getHeader=function(a){return this.headers[a.toLowerCase()]},g.prototype.handle=function(a){if(a.readyState===2&&h.status2){try{this.statusCode=a.status,this.headers=i(a)}catch(b){h.status2=!1}h.status2&&this.emit("ready")}else if(h.streaming&&a.readyState===3){try{this.statusCode||(this.statusCode=a.status,this.headers=i(a),this.emit("ready"))}catch(b){}try{this.write(a)}catch(b){h.streaming=!1}}else a.readyState===4&&(this.statusCode||(this.statusCode=a.status,this.emit("ready")),this.write(a),a.error?this.emit("error",a.responseText):this.emit("end"))},g.prototype.write=function(a){a.responseText.length>this.offset&&(this.emit("data",a.responseText.slice(this.offset)),this.offset=a.responseText.length)}}),require.define("/entry.js",function(a,b,c,d,e){function i(a){l(h.resolve(window.location.pathname,a),function(a){a.run()})}function k(a){if(a.cache)return a.cache;var b=Function(["require","module","exports"],a.source),c={exports:{}};return b.apply(null,[function(c){return a.requires[c].run()},c,c.exports]),c.exports}function l(a,b){if(j[a])return b(j[a]);j[a]={};var c={path:a};g.get(c,function(c){var d="";c.on("data",function(a){d+=a}),c.on("end",function(){m(a,d,b)})})}function m(a,b,c){var d=f(b),e=d.length;j[a].source=b,j[a].requires={},j[a].run=function(){return k(j[a])},e===0&&c(j[a]),d.forEach(function(b){l(h.resolve(h.dirname(a),b),function(d){j[a].requires[b]=d,--e===0&&c(j[a])})})}var f=a("detective"),g=a("http-browserify"),h=a("path");(function(){function a(){if(document.readyState==="loading")return;document.removeEventListener("readystatechange",a);var b=document.querySelectorAll('script[type="text/wreq"]');for(var c=0;c<b.length;c++)if(b[c].src){var d=b[c].src.replace(/^https?:\/\/[^\/]+/,"");i(d)}else{var d="#"+Math.random().toString().slice(2);m(d,b[c].innerHTML,function(a){a.run()})}}a(),document.addEventListener("readystatechange",a)})();var j={}}),require("/entry.js")})();
+(),h=f[2];c[g]!==undefined?Array.isArray&&Array.isArray(c[g])||c[g]instanceof Array?c[g].push(h):c[g]=[c[g],h]:c[g]=h}else c[e]=!0}return c}var f=a("events").EventEmitter,g=b.exports=function(a){this.offset=0};g.prototype=new f;var h={streaming:!0,status2:!0};g.prototype.getHeader=function(a){return this.headers[a.toLowerCase()]},g.prototype.handle=function(a){if(a.readyState===2&&h.status2){try{this.statusCode=a.status,this.headers=i(a)}catch(b){h.status2=!1}h.status2&&this.emit("ready")}else if(h.streaming&&a.readyState===3){try{this.statusCode||(this.statusCode=a.status,this.headers=i(a),this.emit("ready"))}catch(b){}try{this.write(a)}catch(b){h.streaming=!1}}else a.readyState===4&&(this.statusCode||(this.statusCode=a.status,this.emit("ready")),this.write(a),a.error?this.emit("error",a.responseText):this.emit("end"))},g.prototype.write=function(a){a.responseText.length>this.offset&&(this.emit("data",a.responseText.slice(this.offset)),this.offset=a.responseText.length)}}),require.define("/entry.js",function(a,b,c,d,e){function i(a){l(h.resolve(window.location.pathname,a),function(a){a.run()})}function k(a){if(a.cache)return a.cache;var b=Function(["require","module","exports"],a.source),c={exports:{}};return b.apply(null,[function(c){return a.requires[c].run()},c,c.exports]),c.exports}function l(a,b){if(j[a])return b(j[a]);j[a]={};var c={path:a};g.get(c,function(c){var d="";c.on("data",function(a){d+=a}),c.on("end",function(){m(a,d,b)})})}function m(a,b,c){var d=f(b),e=d.length;j[a].source=b+"\n//@ sourceURL="+a,j[a].requires={},j[a].run=function(){return k(j[a])},e===0&&c(j[a]),d.forEach(function(b){l(h.resolve(h.dirname(a),b),function(d){j[a].requires[b]=d,--e===0&&c(j[a])})})}var f=a("detective"),g=a("http-browserify"),h=a("path");(function(){function a(){if(document.readyState==="loading")return;document.removeEventListener("readystatechange",a);var b=document.querySelectorAll('script[type="text/wreq"]');for(var c=0;c<b.length;c++)if(b[c].src){var d=b[c].src.replace(/^https?:\/\/[^\/]+/,"");i(d)}else{var d="#"+Math.random().toString().slice(2);m(d,b[c].innerHTML,function(a){a.run()})}}a(),document.addEventListener("readystatechange",a)})();var j={}}),require("/entry.js")})()
Please sign in to comment.
Something went wrong with that request. Please try again.