text: !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define("Debugger",[],t):"object"==typeof exports?exports.Debugger=t():e.Debugger=t()}(global,(function(){return function(e){var t={};function r(n){if(t[n])return t[n].exports;var a=t[n]={i:n,l:!1,exports:{}};return e[n].call(a.exports,a,a.exports,r),a.l=!0,a.exports}return r.m=e,r.c=t,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var a in e)r.d(n,a,function(t){return e[t]}.bind(null,a));return n},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=53)}([function(e,t){e.exports=require("debug")},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=o(r(2));t.isDeliberatelySkippedNodeType=s,t.isSkippedNodeType=function(e){return s(e)||["VariableDeclarationStatement","Mapping","Block","InlineAssembly","YulTypedName"].includes(e.nodeType)||e.nodeType.includes("TypeName")||void 0!==e.typeDescriptions&&"stringliteral"===a.Ast.Utils.typeClass(e)},t.prefixName=function(e,t){return Object.defineProperty(t,"name",{value:`${e}.${t.name}`,configurable:!0}),t},t.makePath=function(e,t){return`${e}:${t}`},t.popNWhere=function(e,t,r){let n=e.slice();for(;t>0&&n.length>0;){let e=n[n.length-1];r(e)&&t--,n.pop()}return n},t.keccak256=c,t.stableKeccak256=l,t.makeAssignment=function(e,t){let r=l(e);return(0,n.default)({},e,{id:r,ref:t})},t.isCallMnemonic=function(e){return["CALL","DELEGATECALL","STATICCALL","CALLCODE"].includes(e)},t.isShortCallMnemonic=function(e){return["DELEGATECALL","STATICCALL"].includes(e)},t.isDelegateCallMnemonicBroad=function(e){return["DELEGATECALL","CALLCODE"].includes(e)},t.isDelegateCallMnemonicStrict=function(e){return["DELEGATECALL"].includes(e)},t.isStaticCallMnemonic=function(e){return["STATICCALL"].includes(e)},t.isCreateMnemonic=function(e){return["CREATE","CREATE2"].includes(e)},t.isSelfDestructMnemonic=function(e){return["SELFDESTRUCT","SUICIDE"].includes(e)};var a=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t}(r(3)),i=o(r(58));function o(e){return e&&e.__esModule?e:{default:e}}function s(e){return["ContractDefinition","VariableDeclaration","YulVariableDeclaration","YulBlock"].includes(e.nodeType)}function c(...e){return a.Conversion.toHexString(a.Evm.Utils.keccak256(...e),a.Evm.Utils.WORD_SIZE)}function l(e){return c({type:"string",value:(0,i.default)(e)})}},function(e,t){e.exports=require("babel-runtime/helpers/extends")},function(e,t){e.exports=require("@truffle/codec")},function(e,t){e.exports=require("reselect-tree")},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(4);const a={depth:-1,error:"",gas:0,memory:[],stack:[],storage:{},gasCost:0,op:"STOP",pc:-1};let i=(0,n.createSelectorTree)({index:e=>e.trace.proc.index,loaded:(0,n.createLeaf)(["/steps"],e=>null!==e),finished:e=>e.trace.proc.finished,finishedOrUnloaded:(0,n.createLeaf)(["/finished","/loaded"],(e,t)=>e||!t),steps:e=>e.trace.transaction.steps,stepsRemaining:(0,n.createLeaf)(["./steps","./index"],(e,t)=>e.length-t),step:(0,n.createLeaf)(["./steps","./index"],(e,t)=>e?e.length>0?e[t]:a:null),next:(0,n.createLeaf)(["./steps","./index"],(e,t)=>t<e.length-1?e[t+1]:a),nextOfSameDepth:(0,n.createLeaf)(["./steps","./index"],(e,t)=>{let r=e[t].depth;for(let n of e.slice(t+1)){if(n.depth===r)return n;if(n.depth<r)return}}),application:{submoduleCount:e=>e.trace.application.submoduleCount}});t.default=i},function(e,t){e.exports=require("redux-saga/effects")},function(e,t){e.exports=require("redux")},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=f(r(11)),a=f(r(12)),i=f(r(2)),o=f(r(0)),s=r(4),c=f(r(21)),l=f(r(5)),u=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t}(r(3)),d=r(1);function f(e){return e&&e.__esModule?e:{default:e}}(0,o.default)("debugger:evm:selectors");const p="00".repeat(u.Evm.Utils.WORD_SIZE);function y({address:e,binary:t},r,n,a){let o,s=Boolean(t);if(e)({context:o,binary:t}=r[e]);else{if(!s)return null;o=n(t)}if(null!=o){let e=a[o];return(0,i.default)({},e,{binary:t})}return{binary:t,isConstructor:s}}function h(e,t=null){let r={trace:(0,s.createLeaf)([e],e=>{if(!e)return null;let{gasCost:t,op:r,pc:n}=e;return{gasCost:t,op:r,pc:n}}),programCounter:(0,s.createLeaf)(["./trace"],e=>e?e.pc:null),isCall:(0,s.createLeaf)(["./trace"],e=>(0,d.isCallMnemonic)(e.op)),isShortCall:(0,s.createLeaf)(["./trace"],e=>(0,d.isShortCallMnemonic)(e.op)),isDelegateCallBroad:(0,s.createLeaf)(["./trace"],e=>(0,d.isDelegateCallMnemonicBroad)(e.op)),isDelegateCallStrict:(0,s.createLeaf)(["./trace"],e=>(0,d.isDelegateCallMnemonicStrict)(e.op)),isStaticCall:(0,s.createLeaf)(["./trace"],e=>(0,d.isStaticCallMnemonic)(e.op)),isCreate:(0,s.createLeaf)(["./trace"],e=>(0,d.isCreateMnemonic)(e.op)),isSelfDestruct:(0,s.createLeaf)(["./trace"],e=>(0,d.isSelfDestructMnemonic)(e.op)),isCreate2:(0,s.createLeaf)(["./trace"],e=>"CREATE2"===e.op),isStore:(0,s.createLeaf)(["./trace"],e=>"SSTORE"===e.op),isLoad:(0,s.createLeaf)(["./trace"],e=>"SLOAD"===e.op),touchesStorage:(0,s.createLeaf)(["./isStore","isLoad"],(e,t)=>e||t),isPop:(0,s.createLeaf)(["./trace"],e=>"POP"===e.op)};if(t){(e=>"string"==typeof e&&(e.startsWith("./")||e.startsWith("../")))(t)&&(t="../"+t),(0,a.default)(r,{isJump:(0,s.createLeaf)(["./trace",t],(e,{stack:t})=>"JUMP"===e.op||"JUMPI"===e.op&&t[t.length-2]!==p),valueStored:(0,s.createLeaf)(["./isStore",t],(e,{stack:t})=>e?t[t.length-2]:null),callAddress:(0,s.createLeaf)(["./isCall",t],(e,{stack:t})=>{if(!e)return null;let r=t[t.length-2];return u.Evm.Utils.toAddress(r)}),createBinary:(0,s.createLeaf)(["./isCreate",t],(e,{stack:t,memory:r})=>{if(!e)return null;const n=2*parseInt(t[t.length-2],16),a=2*parseInt(t[t.length-3],16);return"0x"+r.join("").substring(n,n+a).padEnd(a,"00")}),callData:(0,s.createLeaf)(["./isCall","./isShortCall",t],(e,t,{stack:r,memory:n})=>{if(!e)return null;let a=t?1:0;const i=2*parseInt(r[r.length-4+a],16),o=2*parseInt(r[r.length-5+a],16);return"0x"+n.join("").substring(i,i+o).padEnd(o,"00")}),callValue:(0,s.createLeaf)(["./isCall","./isDelegateCallStrict","./isStaticCall",t],(e,t,r,{stack:n})=>{if(!e||t)return null;if(r)return new c.default(0);let a=n[n.length-3];return u.Conversion.toBN(a)}),createValue:(0,s.createLeaf)(["./isCreate",t],(e,{stack:t})=>{if(!e)return null;let r=t[t.length-1];return u.Conversion.toBN(r)}),storageAffected:(0,s.createLeaf)(["./touchesStorage",t],(e,{stack:t})=>e?t[t.length-1]:null),salt:(0,s.createLeaf)(["./isCreate2",t],(e,{stack:t})=>e?"0x"+t[t.length-4]:null),callContext:(0,s.createLeaf)(["./callAddress","./createBinary","/current/codex/instances","/info/binaries/search","/info/contexts"],(e,t,r,n,a)=>y({address:e,binary:t},r,n,a))})}return r}const m=(0,s.createSelectorTree)({state:e=>e.evm,info:{contexts:(0,s.createLeaf)(["/state"],e=>e.info.contexts.byContext),binaries:{search:(0,s.createLeaf)(["/info/contexts"],e=>t=>(u.Contexts.Utils.findContext(e,t)||{context:null}).context)}},transaction:{globals:{tx:(0,s.createLeaf)(["/state"],e=>e.transaction.globals.tx),block:(0,s.createLeaf)(["/state"],e=>e.transaction.globals.block)},status:(0,s.createLeaf)(["/state"],e=>e.transaction.status),initialCall:(0,s.createLeaf)(["/state"],e=>e.transaction.initialCall),startingContext:(0,s.createLeaf)(["/current/callstack","/current/codex/instances","/info/binaries/search","/info/contexts"],(e,t,r,n)=>e.length>0?y(e[0],t,r,n):null),affectedInstances:(0,s.createLeaf)(["/state"],e=>e.transaction.affectedInstances.byAddress)},current:{callstack:e=>e.evm.proc.callstack,call:(0,s.createLeaf)(["./callstack"],e=>e.length?e[e.length-1]:{}),context:(0,s.createLeaf)(["./call","./codex/instances","/info/binaries/search","/info/contexts"],y),state:(0,a.default)({},...["depth","error","gas","memory","stack","storage"].map(e=>({[e]:(0,s.createLeaf)([l.default.step],t=>t[e])}))),step:(0,i.default)({},h(l.default.step,"./state"),{createdAddress:(0,s.createLeaf)(["./isCreate","/nextOfSameDepth/state/stack","./isCreate2","./create2Address"],(e,t,r,n)=>{if(!e)return null;let a=t?u.Evm.Utils.toAddress(t[t.length-1]):u.Evm.Utils.ZERO_ADDRESS;return a===u.Evm.Utils.ZERO_ADDRESS&&r?n:a}),create2Address:(0,s.createLeaf)(["./isCreate2","./createBinary","../call","../state/stack"],(e,t,{storageAddress:r},n)=>e?u.Evm.Utils.toAddress("0x"+(0,d.keccak256)({type:"bytes",value:"0xff"+r.slice(2)+n[n.length-4]+(0,d.keccak256)({type:"bytes",value:t}).slice(2)}).slice(2+2*(u.Evm.Utils.WORD_SIZE-u.Evm.Utils.ADDRESS_SIZE))):null),isInstantCallOrCreate:(0,s.createLeaf)(["./isCall","./isCreate","./isContextChange"],(e,t,r)=>(e||t)&&!r),isContextChange:(0,s.createLeaf)(["/current/state/depth","/next/state/depth"],(e,t)=>e!==t),isNormalHalting:(0,s.createLeaf)(["./isHalting","./returnStatus"],(e,t)=>e&&t),isHalting:(0,s.createLeaf)(["/current/state/depth","/next/state/depth",l.default.stepsRemaining],(e,t,r)=>t<e||0===r),isExceptionalHalting:(0,s.createLeaf)(["./isHalting","./returnStatus"],(e,t)=>e&&!t),returnStatus:(0,s.createLeaf)(["./isHalting","./isInstantCallOrCreate","/next/state",l.default.stepsRemaining,"/transaction/status"],(e,t,{stack:r},n,a)=>e||t?n<=1?a:r[r.length-1]!==p:null),returnValue:(0,s.createLeaf)(["./trace","./isExceptionalHalting","../state"],(e,t,{stack:r,memory:n})=>{if("RETURN"!==e.op&&"REVERT"!==e.op)return"0x";if(t&&"REVERT"!==e.op)return"0x";const a=2*parseInt(r[r.length-1],16),i=2*parseInt(r[r.length-2],16);return"0x"+n.join("").substring(a,a+i).padEnd(i,"00")}),valueLoaded:(0,s.createLeaf)(["./isLoad","/next/state"],(e,{stack:t})=>e?t[t.length-1]:null),beneficiary:(0,s.createLeaf)(["./isSelfDestruct","../state","../call"],(e,{stack:t},{storageAddress:r})=>{if(!e)return null;const n=u.Evm.Utils.toAddress(t[t.length-1]);return n!==r?n:null})}),codex:{_:(0,s.createLeaf)(["/state"],e=>e.proc.codex),storage:(0,s.createLeaf)(["./_","../state/storage","../call"],(e,t,{storageAddress:r})=>r===u.Evm.Utils.ZERO_ADDRESS?t:e[e.length-1].accounts[r].storage),instances:(0,s.createLeaf)(["./_"],e=>(0,a.default)({},...(0,n.default)(e[e.length-1].accounts).map(([e,{code:t,context:r}])=>({[e]:{address:e,binary:t,context:r}}))))}},next:{state:(0,a.default)({},...["depth","error","gas","memory","stack","storage"].map(e=>({[e]:(0,s.createLeaf)([l.default.next],t=>t[e])}))),step:h(l.default.next,"./state")},nextOfSameDepth:{state:(0,a.default)({},...["depth","error","gas","memory","stack","storage"].map(e=>({[e]:(0,s.createLeaf)([l.default.nextOfSameDepth],t=>t?t[e]:null)})))}});t.default=m},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=f(r(11)),a=f(r(12)),i=f(r(2)),o=f(r(0)),s=r(4),c=f(r(64)),l=f(r(34)),u=f(r(8)),d=f(r(5));function f(e){return e&&e.__esModule?e:{default:e}}const p=(0,o.default)("debugger:solidity:selectors");function y(e){return p("context: %O",e),void 0!==e.compiler&&"solc"===e.compiler.name&&l.default.satisfies(e.compiler.version,">=0.5.1",{includePrerelease:!0})&&!e.isConstructor}function h(e){return{instruction:(0,s.createLeaf)(["/current/instructionAtProgramCounter",e.programCounter],(e,t)=>e[t]||{}),modifierDepth:(0,s.createLeaf)(["./instruction"],e=>e.modifierDepth),source:(0,s.createLeaf)(["/current/sources","./instruction"],(e,{file:t})=>e&&e[t]||{}),findOverlappingRange:(0,s.createLeaf)(["./source","/current/overlapFunctions"],({index:e},t)=>(t||{})[e]),sourceRange:(0,s.createLeaf)(["./instruction"],c.default.getSourceRange),pointerAndNode:(0,s.createLeaf)(["./findOverlappingRange","./sourceRange"],(e,t)=>e?c.default.findRange(e,t.start,t.length):null),pointer:(0,s.createLeaf)(["./pointerAndNode"],e=>e?e.pointer:null),node:(0,s.createLeaf)(["./source","./pointerAndNode"],({ast:e},t)=>t?t.node:e)}}let m=(0,s.createSelectorTree)({state:e=>e.solidity,info:{sources:(0,s.createLeaf)(["/state"],e=>e.info.sources)},transaction:{bottomStackframeRequiresPhantomFrame:(0,s.createLeaf)([u.default.transaction.startingContext],y)},current:(0,i.default)({sourceIds:(0,s.createLeaf)(["/info/sources",u.default.current.context],(e,t)=>{if(!t)return p("no context"),null;const{compilationId:r,context:n}=t;p("compilationId: %o",r);let i=[],o=[];return r&&e.byCompilationId[r]&&(i=e.byCompilationId[r].byIndex),e.byContext[n]&&(o=e.byContext[n].byIndex),(0,a.default)([],i,o)}),sources:(0,s.createLeaf)(["/views/sources","/current/sourceIds"],(e,t)=>t?t.map(t=>e[t]):null),sourceMap:(0,s.createLeaf)([u.default.current.context],e=>e?e.sourceMap:null),humanReadableSourceMap:(0,s.createLeaf)(["./sourceMap"],e=>e?c.default.getHumanReadableSourceMap(e):null),functionDepthStack:e=>e.solidity.proc.functionDepthStack,nextFrameIsPhantom:e=>e.solidity.proc.nextFrameIsPhantom,functionDepth:(0,s.createLeaf)(["./functionDepthStack"],e=>e[e.length-1]),callRequiresPhantomFrame:(0,s.createLeaf)([u.default.current.context],y),instructions:(0,s.createLeaf)(["./sources",u.default.current.context,"./humanReadableSourceMap"],(e,t,r)=>t?(p("sources before processing: %O",e),c.default.getProcessedInstructionsForBinary((e||[]).map(e=>e?e.source:void 0),t.binary,r)):[]),instructionAtProgramCounter:(0,s.createLeaf)(["./instructions"],e=>(0,a.default)({},...e.map(e=>({[e.pc]:e}))))},h(u.default.current.step),{isSourceRangeFinalRaw:(0,s.createLeaf)(["./instructionAtProgramCounter",u.default.current.step.programCounter,u.default.next.step.programCounter,u.default.current.step.isContextChange],(e,t,r,n)=>!(!n&&e[r])||(t=e[t],r=e[r],t.start!=r.start||t.length!=r.length||t.file!=r.file)),isSourceRangeFinal:(0,s.createLeaf)(["./isSourceRangeFinalRaw","./source","/next/source",u.default.current.step.isContextChange],(e,t,r,n)=>n||e&&(t.internal||!r.internal)),functionsByProgramCounter:(0,s.createLeaf)(["./instructions","./sources","./overlapFunctions",u.default.current.context],(e,t,r,{compilationId:n})=>c.default.getFunctionsByProgramCounter(e,t.map(({ast:e})=>e),r,n)),isMultiline:(0,s.createLeaf)(["./sourceRange"],({lines:e})=>e.start.line!=e.end.line),willJump:(0,s.createLeaf)([u.default.current.step.isJump],e=>e),jumpDirection:(0,s.createLeaf)(["./instruction"],(e={})=>e.jump||"-"),willCall:(0,s.createLeaf)([u.default.current.step.isCall,u.default.current.step.isCreate,u.default.current.step.isInstantCallOrCreate],(e,t,r)=>(e||t)&&!r),willReturn:(0,s.createLeaf)([u.default.current.step.isHalting],e=>e),nextUserStep:(0,s.createLeaf)(["./instructionAtProgramCounter","/current/sources",d.default.steps,d.default.index],(e,t,r,n)=>r.slice(n+1).find(({pc:r})=>e[r]&&-1!==e[r].file&&!(t[e[r].file]&&t[e[r].file].internal))),overlapFunctions:(0,s.createLeaf)(["/views/overlapFunctions","/current/sourceIds"],(e,t)=>t?t.map(t=>e[t]):null)}),next:h(u.default.next.step),views:{sources:(0,s.createLeaf)(["/info/sources"],e=>e.byId),overlapFunctions:(0,s.createLeaf)(["/views/sources"],e=>(0,a.default)({},...(0,n.default)(e).map(([e,{ast:t}])=>({[e]:c.default.makeOverlapFunction(t)}))))}});t.default=m},function(e,t){e.exports=require("path")},function(e,t){e.exports=require("babel-runtime/core-js/object/entries")},function(e,t){e.exports=require("babel-runtime/core-js/object/assign")},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.saveSteps=function(e){return{type:n,steps:e}},t.next=function(){return{type:a}},t.tick=function(){return{type:i}},t.tock=function(){return{type:o}},t.endTrace=function(){return{type:s}},t.reset=function(){return{type:c}},t.unloadTransaction=function(){return{type:l}},t.backtick=function(){return{type:u}},t.setSubmoduleCount=function(e){return{type:d,count:e}};const n=t.SAVE_STEPS="TRACE_SAVE_STEPS";const a=t.NEXT="TRACE_NEXT";const i=t.TICK="TRACE_TICK";const o=t.TOCK="TRACE_TOCK";const s=t.END_OF_TRACE="TRACE_EOT";const c=t.RESET="TRACE_RESET";const l=t.UNLOAD_TRANSACTION="TRACE_UNLOAD_TRANSACTION";const u=t.BACKTICK="TRACE_BACKTICK";const d=t.SET_SUBMODULE_COUNT="TRACE_SET_SUBMODULE_COUNT"},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=d(r(66));t.setSubmoduleCount=function*(e){yield(0,i.put)(c.setSubmoduleCount(e))},t.addSubmoduleToCount=function*(e=1){let t=yield(0,i.select)(l.default.application.submoduleCount);yield(0,i.put)(c.setSubmoduleCount(t+e))},t.advance=function*(){yield(0,i.put)(c.next()),f("TOCK to take"),yield(0,i.take)([c.TOCK,c.END_OF_TRACE]),f("TOCK taken")},t.signalTickSagaCompletion=function*(){yield(0,i.put)(c.backtick())},t.processTrace=function*(e){yield(0,i.put)(c.saveSteps(e));let t=new n.default,r=new n.default,a={};for(let n=0;n<e.length;n++){const{op:i,depth:c,stack:l,memory:u}=e[n];if((0,o.isCallMnemonic)(i))t.add(s.Evm.Utils.toAddress(l[l.length-2]));else if((0,o.isCreateMnemonic)(i)){const t=e.slice(n+1).find(e=>e.depth===c);if(t){const e=t.stack,r=s.Evm.Utils.toAddress(e[e.length-1]);if(r!==s.Evm.Utils.ZERO_ADDRESS){const e=2*parseInt(l[l.length-2],16),t=2*parseInt(l[l.length-3],16),n="0x"+u.join("").substring(e,e+t).padEnd(t,"00");a[r]=n}}}else(0,o.isSelfDestructMnemonic)(i)&&r.add(s.Evm.Utils.toAddress(l[l.length-1]))}return{calls:[...t],selfdestructs:[...r],creations:a}},t.reset=function*(){yield(0,i.put)(c.reset())},t.unload=function*(){yield(0,i.put)(c.unloadTransaction())},t.saga=y;var a=d(r(0)),i=r(6),o=r(1),s=u(r(3)),c=u(r(13)),l=d(r(5));function u(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t}function d(e){return e&&e.__esModule?e:{default:e}}const f=(0,a.default)("debugger:trace:sagas");function*p(){let e=yield(0,i.select)(l.default.stepsRemaining);f("remaining: %o",e);let t=yield(0,i.select)(l.default.steps);f("total steps: %o",t.length);let r=0;if(e>0){for(f("putting TICK"),r=yield(0,i.select)(l.default.application.submoduleCount),yield(0,i.put)(c.tick()),f("put TICK");r>0;)yield(0,i.take)(c.BACKTICK),f("got BACKTICK"),r--;e--}e?(f("putting TOCK"),yield(0,i.put)(c.tock()),f("put TOCK")):(f("putting END_OF_TRACE"),yield(0,i.put)(c.endTrace()),f("put END_OF_TRACE"))}function*y(){yield(0,i.takeEvery)(c.NEXT,p)}t.default=(0,o.prefixName)("trace",y)},function(e,t){e.exports=require("util")},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.BLOCK_DEFINITION=t.TX_DEFINITION=t.MSG_DEFINITION=t.NOW_DEFINITION=void 0;var n=v(r(26)),a=v(r(19)),i=v(r(2)),o=v(r(11)),s=v(r(12)),c=v(r(0)),l=r(4),u=v(r(20)),d=v(r(63)),f=v(r(34)),p=r(1),y=v(r(5)),h=v(r(8)),m=v(r(9)),g=v(r(22)),b=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t}(r(3));function v(e){return e&&e.__esModule?e:{default:e}}const _=(0,c.default)("debugger:data:selectors"),E=e=>e;function T(e,t,r,n=null,a=null){for(;e&&!t.includes(e.nodeType);)if(void 0!==e.id)e=r[r[e.id].parentId].definition;else{if(null===n||null===a||""===n)return null;n=n.replace(/\/[^/]*$/,""),e=u.default.get(a,n)}return e}function A(e,t){let r;switch(e.nodeType){case"ModifierInvocation":r=e.modifierName.referencedDeclaration;break;case"InheritanceSpecifier":r=e.baseName.referencedDeclaration;break;default:_("bad invocation node")}let n=t[r].definition;switch(n.nodeType){case"ModifierDefinition":return n;case"ContractDefinition":return n.nodes.find(e=>"FunctionDefinition"===e.nodeType&&"constructor"===b.Ast.Utils.functionKind(e));default:return}}function S(e){let{context:t,contractName:r,binary:n,contractId:a,contractKind:i,isConstructor:o,abi:s,payable:c,compiler:l,compilationId:u}=e;return{context:t,contractName:r,binary:n,contractId:a,contractKind:i,isConstructor:o,abi:b.AbiData.Utils.computeSelectors(s),fallbackAbi:{fallback:(s||[]).find(e=>"fallback"===e.type)||null,receive:(s||[]).find(e=>"receive"===e.type)||null},payable:c,compiler:l,compilationId:u}}const R=t.NOW_DEFINITION={id:-1,src:"0:0:-1",name:"now",nodeType:"VariableDeclaration",typeDescriptions:{typeIdentifier:"t_uint256",typeString:"uint256"}},C=t.MSG_DEFINITION={id:-1,src:"0:0:-1",name:"msg",nodeType:"VariableDeclaration",typeDescriptions:{typeIdentifier:"t_magic_message",typeString:"msg"}},O=t.TX_DEFINITION={id:-1,src:"0:0:-1",name:"tx",nodeType:"VariableDeclaration",typeDescriptions:{typeIdentifier:"t_magic_transaction",typeString:"tx"}},L=t.BLOCK_DEFINITION={id:-1,src:"0:0:-1",name:"block",nodeType:"VariableDeclaration",typeDescriptions:{typeIdentifier:"t_magic_block",typeString:"block"}};const I=(0,l.createSelectorTree)({state:e=>e.data,views:{atLastInstructionForSourceRange:(0,l.createLeaf)([m.default.current.isSourceRangeFinal],e=>e),scopes:{_:(0,l.createLeaf)(["/info/scopes"],e=>(0,s.default)({},...(0,o.default)(e).map(([e,{byAstRef:t}])=>({[e]:t})))),inlined:(0,l.createLeaf)(["./_",m.default.views.sources],(e,t)=>(0,s.default)({},...(0,o.default)(e).map(([e,r])=>({[e]:(0,s.default)({},...(0,o.default)(r).map(([e,r])=>({[e]:(0,i.default)({},r,{definition:u.default.get(t[r.sourceId].ast,r.pointer)})})))}))))},userDefinedTypes:(0,l.createLeaf)(["/info/userDefinedTypes","./referenceDeclarations","./scopes/inlined",m.default.views.sources],(e,t,r,n)=>(0,s.default)({},...e.map(({sourceId:e,id:a})=>{_("id: %d",a),_("sourceId: %s",e),_("scope: %o",r[e][a]);const i=r[e][a].definition;_("node: %o",i);const{compilationId:o,compiler:s,internal:c}=n[e];if(_("compilationId: %s",o),c)return{};const l=b.Ast.Import.definitionToStoredType(i,o,s,t[o]);return _("type: %o",l),{[l.id]:l}}))),contractAllocationInfo:(0,l.createLeaf)(["/info/userDefinedTypes","/views/scopes/inlined",m.default.views.sources,h.default.info.contexts],(e,t,r,n)=>(0,a.default)(e).filter(({sourceId:e,id:n})=>!r[e].internal&&"ContractDefinition"===t[e][n].definition.nodeType).map(({sourceId:e,id:i})=>{_("id: %O",i);const o=r[e].compilationId;_("compilationId: %O",o);let s=(0,a.default)(n).find(e=>!e.isConstructor&&e.compilationId===o&&e.contractId===i),c=(0,a.default)(n).find(e=>e.isConstructor&&e.compilationId===o&&e.contractId===i),l=s?s.immutableReferences:void 0;return{contractNode:t[e][i].definition,compilationId:o,immutableReferences:l,compiler:r[e].compiler,abi:(s||{}).abi,deployedContext:s,constructorContext:c}})),referenceDeclarations:(0,l.createLeaf)(["./scopes/inlined","/info/userDefinedTypes","/info/taggedOutputs",m.default.views.sources],(e,t,r,n)=>(0,d.default)({},...t.concat(r).map(({id:t,sourceId:r})=>{const a=n[r];return a.internal?{}:{[a.compilationId]:{[t]:e[r][t].definition}}}))),mappingKeys:(0,l.createLeaf)(["/proc/mappedPaths","/current/address"],(e,t)=>[].concat(...(0,a.default)((e.byAddress[t]||{byType:{}}).byType).map(({bySlotAddress:e})=>(0,a.default)(e))).filter(e=>void 0!==e.key)),blockNumber:(0,l.createLeaf)([h.default.transaction.globals.block],e=>e.number.toString()),instances:(0,l.createLeaf)([h.default.current.codex.instances],e=>(0,s.default)({},...(0,o.default)(e).map(([e,{binary:t}])=>({[e]:b.Conversion.toBytes(t)})))),contexts:(0,l.createLeaf)([h.default.info.contexts],e=>(0,s.default)({},...(0,a.default)(e).filter(e=>!e.isConstructor).map(e=>({[e.contractId]:S(e)}))))},info:{scopes:(0,l.createLeaf)(["/state"],e=>e.info.scopes.bySourceId),allocations:{storage:(0,l.createLeaf)(["/state"],e=>e.info.allocations.storage),state:(0,l.createLeaf)(["/state"],e=>e.info.allocations.state),memory:(0,l.createLeaf)(["/state"],e=>e.info.allocations.memory),abi:(0,l.createLeaf)(["/state"],e=>e.info.allocations.abi),calldata:(0,l.createLeaf)(["/state"],e=>e.info.allocations.calldata),returndata:(0,l.createLeaf)(["/state"],e=>e.info.allocations.returndata)},userDefinedTypes:(0,l.createLeaf)(["/state"],e=>e.info.userDefinedTypes),taggedOutputs:(0,l.createLeaf)(["/state"],e=>e.info.taggedOutputs)},proc:{assignments:(0,l.createLeaf)(["/state"],e=>e.proc.assignments.byId),mappedPaths:(0,l.createLeaf)(["/state"],e=>e.proc.mappedPaths)},current:{state:{stack:(0,l.createLeaf)([h.default.current.state.stack],e=>(e||[]).map(e=>b.Conversion.toBytes(e))),memory:(0,l.createLeaf)([h.default.current.state.memory],e=>b.Conversion.toBytes(e.join(""))),code:(0,l.createLeaf)([h.default.current.context],({binary:e})=>b.Conversion.toBytes(e)),calldata:(0,l.createLeaf)([h.default.current.call],({data:e})=>b.Conversion.toBytes(e)),storage:(0,l.createLeaf)([h.default.current.codex.storage],e=>(0,s.default)({},...(0,o.default)(e).map(([e,t])=>({["0x"+e]:b.Conversion.toBytes(t)})))),specials:(0,l.createLeaf)(["/current/address",h.default.current.call,h.default.transaction.globals],(e,{sender:t,value:r},{tx:n,block:a})=>(0,i.default)({this:b.Conversion.toBytes(e),sender:b.Conversion.toBytes(t),value:b.Conversion.toBytes(r)},(0,s.default)({},...(0,o.default)(n).map(([e,t])=>({[e]:b.Conversion.toBytes(t)}))),(0,s.default)({},...(0,o.default)(a).map(([e,t])=>({[e]:b.Conversion.toBytes(t)})))))},compilationId:(0,l.createLeaf)([h.default.current.context],({compilationId:e})=>e),sourceIndex:(0,l.createLeaf)([m.default.current.source],({index:e})=>e),language:(0,l.createLeaf)([m.default.current.source],({language:e})=>e),internalSourceFor:(0,l.createLeaf)([m.default.current.source],({internalFor:e})=>e||null),root:(0,l.createLeaf)([m.default.current.source],({ast:e})=>e),scopes:{_:(0,l.createLeaf)(["./raw","./inlined/raw"],(e,t)=>(0,s.default)({},...(0,o.default)(e).map(([r,n])=>{let o=t[r].definition;if("ContractDefinition"===o.nodeType){_("contract id %d",r);let a=(0,i.default)({},n);const s=o.linearizedBaseContracts.slice().reverse();return s.pop(),a.variables=[].concat(...s.map(t=>e[t].variables||[])).filter(e=>"private"!==t[e.astRef].definition.visibility).concat(e[r].variables||[]).filter(e=>{_("variable %O",e);const r=t[e.astRef].definition;return!(r.constant||"constant"===r.mutability)||b.Ast.Utils.isSimpleConstant(r.value)}),{[r]:a}}if("SourceUnit"===o.nodeType){let e=(0,i.default)({},n);return e.variables=(0,a.default)(o.exportedSymbols).map(e=>e[0]).filter(e=>{const r=t[e].definition;return"VariableDeclaration"===r.nodeType&&(r.constant||"constant"===r.mutability)&&b.Ast.Utils.isSimpleConstant(r.value)}).map(e=>({astRef:e,name:t[e].definition.name,sourceId:t[e].sourceId})),{[r]:e}}return{[r]:n}}))),raw:(0,l.createLeaf)(["/views/scopes",m.default.current.sourceIds],(e,t)=>(0,s.default)({},...t.map(t=>e[t]))),inlined:{_:(0,l.createLeaf)(["./raw","../_"],(e,t)=>(0,s.default)({},...(0,o.default)(e).map(([e,r])=>({[e]:(0,i.default)({},r,{variables:t[e].variables})})))),raw:(0,l.createLeaf)(["/views/scopes/inlined",m.default.current.sourceIds],(e,t)=>(0,s.default)({},...t.map(t=>e[t])))}},referenceDeclarations:(0,l.createLeaf)(["/views/referenceDeclarations","./compilationId"],(e,t)=>e[t]),allocations:{state:(0,l.createLeaf)(["/info/allocations/state","../compilationId",h.default.current.context],(e,t,{isConstructor:r})=>{_("compilationId: %s",t),_("allAllocations: %o",e);const n=t?e[t]:{};let a=(0,s.default)({},...(0,o.default)(n).map(([e,t])=>({[e]:{members:t.members.map(e=>(0,i.default)({},e))}})));if(r)for(const e in a){const t=a[e];let r=4*b.Evm.Utils.WORD_SIZE;for(const e of t.members)"code"!==e.pointer.location&&"nowhere"!==e.pointer.location||(e.pointer={location:"memory",start:r,length:b.Evm.Utils.WORD_SIZE},r+=b.Evm.Utils.WORD_SIZE)}return(0,s.default)({},...(0,o.default)(a).map(([e,t])=>({[e]:{members:(0,s.default)({},...t.members.map(e=>({[e.definition.id]:e})))}})))})},compiler:(0,l.createLeaf)([h.default.current.context],({compiler:e})=>e),bareLetsInYulAreHit:(0,l.createLeaf)(["./compiler"],e=>void 0!==e&&"solc"===e.name&&f.default.satisfies(e.version,">=0.6.8",{includePrerelease:!0})),node:(0,l.createLeaf)([m.default.current.node],E),pointer:(0,l.createLeaf)([m.default.current.pointer],E),astRef:(0,l.createLeaf)([m.default.current.node,m.default.current.pointer,"./sourceIndex"],(e,t,r)=>e?void 0!==e.id?e.id:(0,p.makePath)(r,t):null),scope:(0,l.createLeaf)(["./node"],E),contract:(0,l.createLeaf)(["./node","./scopes/inlined","./pointer","./root"],(e,t,r,n)=>T(e,["ContractDefinition","SourceUnit"],t,r,n)),contractForBytecode:(0,l.createLeaf)([h.default.current.context,"./scopes/inlined"],({contractId:e},t)=>(t[e]||{definition:null}).definition),fallbackOutputForContext:(0,l.createLeaf)(["./contractForBytecode"],e=>{if(!e)return null;const t=e.nodes.find(e=>"FunctionDefinition"===e.nodeType&&"fallback"===b.Ast.Utils.functionKind(e));return t&&t.returnParameters.parameters[0]||null}),function:(0,l.createLeaf)(["./node","./scopes/inlined","./pointer","./root"],(e,t,r,n)=>T(e,["FunctionDefinition","ModifierDefinition","ContractDefinition","SourceUnit"],t,r,n)),inModifier:(0,l.createLeaf)(["./function"],e=>e&&"ModifierDefinition"===e.nodeType),inFunctionOrModifier:(0,l.createLeaf)(["./function"],e=>e&&("FunctionDefinition"===e.nodeType||"ModifierDefinition"===e.nodeType)),functionDepth:(0,l.createLeaf)([m.default.current.functionDepth],E),modifierDepth:(0,l.createLeaf)([m.default.current.modifierDepth],E),address:(0,l.createLeaf)([h.default.current.call],e=>e.storageAddress),functionsByProgramCounter:(0,l.createLeaf)([m.default.current.functionsByProgramCounter],e=>e),context:(0,l.createLeaf)([h.default.current.context],S),fallbackBase:(0,l.createLeaf)(["./context"],({abi:e})=>(0,n.default)(e).length>0?1:0),errorLocation:(0,l.createLeaf)([g.default.current.innerReturnPosition,g.default.current.lastPosition],(e,t)=>e||t||{}),errorNode:(0,l.createLeaf)(["./errorLocation","/views/scopes/inlined"],(e,t)=>{const r=(e.source||{}).id,n=(e.node||{}).id;return void 0!==r&&void 0!==n?t[r][n].definition:null}),errorId:(0,l.createLeaf)(["./errorNode","./compilationId"],(e,t)=>{if(null!==e)switch(e.nodeType){case"RevertStatement":e=e.errorCall;case"FunctionCall":const r=e.expression.referencedDeclaration;return b.Contexts.Import.makeTypeId(r,t);default:return}}),aboutToModify:(0,l.createLeaf)(["./node","./modifierInvocation","./modifierArgumentIndex","/next/node","/next/modifierInvocation",h.default.current.step.isContextChange],(e,t,r,n,a,i)=>{if(i||!e||void 0===e.id||!n||void 0===n.id||!t||void 0===t.id||!a||void 0===a.id)return!1;if("SourceUnit"===t.nodeType)return!1;if("FunctionDefinition"===n.nodeType||"ModifierDefinition"===n.nodeType)return!1;if("SourceUnit"!==a.nodeType&&a.id===t.id)return!1;if(void 0===r)return!1;let o=t.arguments[r];for(;"typeConversion"===o.kind;){if(e.id===o.id)return!0;o=o.arguments[0]}return e.id===o.id}),modifierInvocation:(0,l.createLeaf)(["./node","./scopes/inlined"],(e,t)=>T(e,["ModifierInvocation","InheritanceSpecifier","SourceUnit"],t)),modifierArgumentIndex:(0,l.createLeaf)(["./scopes","./node","./modifierInvocation"],(e,t,r)=>{if(!r||"SourceUnit"===r.nodeType)return;let n=e[t.id].pointer,a=e[r.id].pointer,i=n.slice(a.length);_("difference %s",i);let o=i.match(/^\/arguments\/(\d+)/);return _("rawIndex %o",o),null!==o?parseInt(o[1]):void 0}),modifierBeingInvoked:(0,l.createLeaf)(["./modifierInvocation","./scopes/inlined"],(e,t)=>{if(e&&"SourceUnit"!==e.nodeType)return A(e,t)}),identifiers:{_:(0,l.createLeaf)(["/current/scopes/inlined","/current/node","/current/pointer","/current/sourceIndex","/current/language"],(e,t,r,n,a)=>{let o={};if(void 0!==t){let a=void 0!==t.id?t.id:(0,p.makePath)(n,r);for(;null!==a&&e[a]&&(_("cur: %o",a),_("scopes[cur]: %o",e[a]),o=(0,s.default)(o,...(e[a].variables||[]).filter(e=>""!==e.name).filter(e=>null==o[e.name]).map(e=>({[e.name]:{astRef:e.astRef}}))),"YulFunctionDefinition"!==e[a].definition.nodeType);)a=void 0!==e[a].parentId?e[a].parentId:a.replace(/\/[^/]*(\/\d+)?$/,"")}return"Solidity"!==a||t&&(t.nodeType.startsWith("Yul")||"InlineAssembly"===t.nodeType)?o:(0,i.default)({},{msg:{builtin:"msg"},tx:{builtin:"tx"},block:{builtin:"block"},this:{builtin:"this"},now:{builtin:"now"}},o)}),definitions:{_:(0,l.createLeaf)(["/current/scopes/inlined","../_","./this","/current/compiler"],(e,t,r,n)=>{_("identifiers: %O",t);let a=(0,s.default)({},...(0,o.default)(t).map(([t,r])=>{if(void 0!==r.astRef){let{definition:n}=e[r.astRef];return{[t]:n}}return{}})),c={msg:C,tx:O,block:L};return r&&(c.this=r),function(e){return e&&"solc"===e.name&&f.default.satisfies(e.version,"~0.7 || >=0.7.0",{includePrerelease:!0})}(n)||(_("adding now"),c.now=R),(0,i.default)({},c,a)}),this:(0,l.createLeaf)(["/current/contract"],e=>{return e&&"ContractDefinition"===e.nodeType?(t=e.name,r=e.id,n=e.contractKind,{id:-1,src:"0:0:-1",name:"this",nodeType:"VariableDeclaration",typeDescriptions:{typeIdentifier:"t_contract$_"+t.replace(/\$/g,"$$".repeat(3))+"_$"+r,typeString:n+" "+t}}):null;var t,r,n})},sections:(0,l.createLeaf)(["./definitions","./refs","/current/scopes/inlined"],(e,t,r)=>{let n={builtin:[],global:[],contract:[],local:[]};for(const[a,i]of(0,o.default)(t))if(a in e)switch(i.location){case"special":n.builtin.push(a);break;case"stack":n.local.push(a);break;case"storage":case"code":case"nowhere":case"memory":n.contract.push(a);break;case"definition":const t=r[e[a].scope].definition;"SourceUnit"===t.nodeType?n.global.push(a):"ContractDefinition"===t.nodeType&&n.contract.push(a)}return n}),refs:(0,l.createLeaf)(["/proc/assignments","./_","./definitions","/current/scopes/inlined","/current/compilationId","/current/internalSourceFor","/current/functionDepth","/current/modifierDepth","/current/inModifier"],(e,t,r,n,a,i,c,l,u)=>(0,s.default)({},...(0,o.default)(t).map(([t,{astRef:o,builtin:s}])=>{let d;if(_("astRef: %o",o),_("builtin: %s",s),void 0!==o){if(d=(0,p.stableKeccak256)({astRef:o,compilationId:a,internalFor:i}),d in e||(d=(0,p.stableKeccak256)({astRef:o,compilationId:a,internalFor:i,stackframe:c,modifierDepth:u?l:null})),_("id after local: %s",d),!(d in e)){const e=r[t];if(_("global definition: %o",e),void 0!==e.scope){if("SourceUnit"===n[e.scope].definition.nodeType&&(!0===e.constant||"constant"===e.mutability))return{[t]:{location:"definition",definition:e.value}}}}}else d=(0,p.stableKeccak256)({builtin:s});_("id: %s",d);let{ref:f}=e[d]||{};return f?{[t]:f}:{}})))},returnStatus:(0,l.createLeaf)([h.default.current.step.returnStatus],e=>null===e?void 0:e),returnAllocation:(0,l.createLeaf)([h.default.current.call,"/current/context","/info/allocations/calldata","./fallbackOutputForContext"],({data:e},{context:t,isConstructor:r,fallbackAbi:n},{constructorAllocations:a,functionAllocations:i},o)=>{if(r){let e=a[t];return e?e.output:null}{let r=e.slice(0,10);_("selector: %s",r),_("bySelector: %o",i[t]);let a=(i[t]||{})[r];return a?a.output:"0x"===e&&null!==n.receive||null===n.fallback||!o?null:b.AbiData.Allocate.FallbackOutputAllocation}}),isCall:(0,l.createLeaf)([h.default.current.step.isCall],E),isCreate:(0,l.createLeaf)([h.default.current.step.isCreate],E),currentCallIsCreate:(0,l.createLeaf)([h.default.current.call],e=>void 0!==e.binary),callContext:(0,l.createLeaf)([h.default.current.step.callContext],S),isPop:(0,l.createLeaf)([h.default.current.step.isPop],E)},next:{state:{stack:(0,l.createLeaf)([h.default.next.state.stack],e=>(e||[]).map(e=>b.Conversion.toBytes(e))),returndata:(0,l.createLeaf)([h.default.current.step.returnValue],e=>b.Conversion.toBytes(e)),calldata:(0,l.createLeaf)([h.default.current.step.isCall,h.default.current.step.isCreate,h.default.current.step.callData,h.default.current.step.createBinary],(e,t,r,n)=>e||t?b.Conversion.toBytes(e?r:n):null)},node:(0,l.createLeaf)([m.default.next.node],E),pointer:(0,l.createLeaf)([m.default.next.pointer],E),modifierInvocation:(0,l.createLeaf)(["./node","/current/scopes/inlined",h.default.current.step.isContextChange],(e,t,r)=>{if(r)return;return T(e,["ModifierInvocation","InheritanceSpecifier","SourceUnit"],t)}),modifierBeingInvoked:(0,l.createLeaf)(["./modifierInvocation","/current/scopes/inlined",h.default.current.step.isContextChange],(e,t,r)=>{if(!r&&e&&"SourceUnit"!==e.nodeType)return A(e,t)})},nextUserStep:{state:{stack:(0,l.createLeaf)([m.default.current.nextUserStep],e=>((e||{}).stack||[]).map(e=>b.Conversion.toBytes(e)))}},nextOfSameDepth:{state:{stack:(0,l.createLeaf)([y.default.nextOfSameDepth],e=>e?(e.stack||[]).map(e=>b.Conversion.toBytes(e)):null)}}});t.default=I},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=b(r(2));t.scope=function*(e,t,r,n,a){yield(0,i.put)(c.scope(e,t,r,n,a))},t.declare=function*(e,t){yield(0,i.put)(c.declare(e.name,e.id,e.scope,t))},t.yulScope=function*(e,t,r,n){yield(0,i.put)(c.scope(void 0,e,n,t,r))},t.yulDeclare=function*(e,t,r,n,a){yield(0,i.put)(c.declare(e.name,(0,o.makePath)(n,t),(0,o.makePath)(n,r),a))},t.defineType=function*(e,t){yield(0,i.put)(c.defineType(e,t))},t.defineTaggedOutput=function*(e,t){yield(0,i.put)(c.defineTaggedOutput(e,t))},t.decode=E,t.decodeReturnValue=function*(){const e=yield(0,i.select)(f.default.views.userDefinedTypes),t=yield(0,i.select)(f.default.next.state),r=yield(0,i.select)(f.default.info.allocations),n=yield(0,i.select)(f.default.views.contexts),a=yield(0,i.select)(f.default.current.context),o=yield(0,i.select)(f.default.current.returnStatus),s=yield(0,i.select)(f.default.current.returnAllocation),c=yield(0,i.select)(f.default.current.errorId);v("returnAllocation: %O",s);const l=h.decodeReturndata({userDefinedTypes:e,state:t,allocations:r,contexts:n,currentContext:a},s,o,c);v("beginning decoding");let u=l.next();for(;!u.done;){v("request received");let e,t=u.value;switch(t.type){case"code":e=yield*T(t.address);break;default:v("unrecognized request type!")}v("sending response"),u=l.next(e)}return v("done decoding"),v("decoded value: %O",u.value),u.value},t.decodeCall=function*(e=!1){const t=yield(0,i.select)(f.default.current.isCall),r=yield(0,i.select)(f.default.current.isCreate);if(!t&&!r&&!e)return null;const a=yield(0,i.select)(f.default.current.currentCallIsCreate),o=yield(0,i.select)(f.default.views.userDefinedTypes);let s=e?yield(0,i.select)(f.default.current.state):yield(0,i.select)(f.default.next.state);e&&a&&(s=(0,n.default)({},s,{calldata:s.code}));const c=yield(0,i.select)(f.default.info.allocations);v("allocations: %O",c);const l=yield(0,i.select)(f.default.views.contexts),u=e?yield(0,i.select)(f.default.current.context):yield(0,i.select)(f.default.current.callContext),d=e?yield(0,i.select)(f.default.current.currentCallIsCreate):r,p=h.decodeCalldata({state:s,userDefinedTypes:o,allocations:c,contexts:l,currentContext:u},d);v("beginning decoding");let y=p.next();for(;!y.done;){v("request received");let e,t=y.value;switch(t.type){case"code":e=yield*T(t.address);break;default:v("unrecognized request type!")}v("sending response"),y=p.next(e)}return v("done decoding"),y.value},t.reset=function*(){yield(0,i.put)(c.reset())},t.recordAllocations=function*(){const e=yield(0,i.select)(f.default.views.contractAllocationInfo),t=yield(0,i.select)(f.default.views.referenceDeclarations),r=yield(0,i.select)(f.default.views.userDefinedTypes),n=h.Storage.Allocate.getStorageAllocations(r),a=h.Memory.Allocate.getMemoryAllocations(r),o=h.AbiData.Allocate.getAbiAllocations(r),s=h.AbiData.Allocate.getCalldataAllocations(e,t,r,o),l=h.AbiData.Allocate.getReturndataAllocations(e,t,r,o),u=h.Storage.Allocate.getStateAllocations(e,t,r,n);yield(0,i.put)(c.allocate(n,a,o,s,l,u))},t.saga=C;var a=b(r(0)),i=r(6),o=r(1),s=r(13),c=g(r(35)),l=g(r(14)),u=g(r(29)),d=g(r(37)),f=b(r(16)),p=b(r(69)),y=b(r(20)),h=g(r(3)),m=b(r(21));function g(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t}function b(e){return e&&e.__esModule?e:{default:e}}const v=(0,a.default)("debugger:data:sagas");function*_(){yield*function*(){if(!(yield(0,i.select)(f.default.views.atLastInstructionForSourceRange)))return;let e,t=yield(0,i.select)(f.default.current.node);if(!t)return;switch(t.nodeType){case"IndexAccess":case"MemberAccess":e=yield(0,i.select)(f.default.nextUserStep.state.stack);break;case"YulFunctionCall":e=yield(0,i.select)(f.default.nextOfSameDepth.state.stack);break;default:e=yield(0,i.select)(f.default.next.state.stack)}if(!e)return;const r=e.length-1;let a=yield(0,i.select)(f.default.current.pointer);const s=yield(0,i.select)(f.default.current.functionDepth),l=yield(0,i.select)(f.default.current.modifierDepth),u=yield(0,i.select)(f.default.current.inModifier),d=yield(0,i.select)(f.default.current.address),g=yield(0,i.select)(f.default.current.compilationId),b=yield(0,i.select)(f.default.current.internalSourceFor);let _,T;if(yield(0,i.select)(f.default.current.aboutToModify)){const e=yield(0,i.select)(f.default.current.modifierBeingInvoked),t=yield(0,i.select)(f.default.current.modifierArgumentIndex);v("currentIndex %d",t);const n=e.parameters.parameters,a=n.slice(t+1),o=(0,p.default)(a.map(h.Ast.Utils.stackSize));v("adjustment %d",o),T=S(g,b,n,r+o,s,l,"ModifierDefinition"===e.nodeType)}else T={};switch(t.nodeType){case"FunctionDefinition":case"ModifierDefinition":if(yield(0,i.select)(f.default.current.isPop))break;const p=yield(0,i.select)(f.default.next.modifierBeingInvoked);if(p&&p.id===t.id)break;const C=t.parameters.parameters;_=S(g,b,C,r,s,l,u),v("Function definition case"),v("assignments %O",_),yield(0,i.put)(c.assign(_));break;case"YulFunctionDefinition":{const e=yield(0,i.select)(f.default.next.pointer);if(null===e||!e.startsWith(a+"/body/")&&!e.startsWith(a+"/returnVariables"))break;let n=[];e.startsWith(a+"/body/")&&(n=(t.returnVariables||[]).map((e,t,r)=>"/returnVariables/"+(r.length-1-t)));const d=(t.parameters||[]).map((e,t)=>"/parameters/"+t);let p=[];if(!(yield(0,i.select)(f.default.current.bareLetsInYulAreHit))){let e=0;for(const r of t.body.statements){if("YulVariableDeclaration"!==r.nodeType||null!=r.value)break;for(let t=0;t<r.variables.length;t++)p.unshift(`/body/statements/${e}/variables/${t}`);e++}}const y=p.concat(n,d);v("suffixes: %O",y),_={};let h=r;const m=yield(0,i.select)(f.default.current.sourceIndex);for(const e of y){const t=(0,o.makePath)(m,a+e),r=(0,o.makeAssignment)({compilationId:g,internalFor:b,astRef:t,stackframe:s,modifierDepth:u?l:null},{location:"stack",from:h,to:h});_[r.id]=r,h--}yield(0,i.put)(c.assign(_));break}case"ContractDefinition":{const e=yield(0,i.select)(f.default.current.allocations.state),r=e[t.id];v("Contract definition case"),v("allocations %O",e),v("allocation %O",r),_={};for(let e in r.members){e=Number(e);const t={compilationId:g,internalFor:b,astRef:e},n=r.members[e].pointer,a=(0,o.makeAssignment)(t,n);_[a.id]=a}const n=t.nodes.find(e=>"FunctionDefinition"===e.nodeType&&"fallback"===h.Ast.Utils.functionKind(e));if(n){const e=n.parameters.parameters[0];if(e){const t=yield(0,i.select)(f.default.current.fallbackBase),r={location:"stack",from:t,to:t+h.Ast.Utils.stackSize(e)-1},n={compilationId:g,internalFor:b,astRef:e.id,stackframe:s,modifierDepth:null},a=(0,o.makeAssignment)(n,r);_[a.id]=a}}v("assignments %O",_),yield(0,i.put)(c.assign(_));break}case"FunctionTypeName":{const e=yield(0,i.select)(f.default.current.scopes.inlined);if(t=e[e[t.id].parentId].definition,"VariableDeclaration"!==t.nodeType)break}case"VariableDeclaration":{const e=t.id;if(v("Variable declaration case"),v("currentDepth %d varId %d",s,e),!(yield(0,i.select)(f.default.current.inFunctionOrModifier))){v("already a contract variable!");break}const n=(0,o.makeAssignment)({compilationId:g,internalFor:b,astRef:e,stackframe:s,modifierDepth:u?l:null},{location:"stack",from:r-h.Ast.Utils.stackSize(t)+1,to:r});_={[n.id]:n},v("assignments: %O",_),yield(0,i.put)(c.assign(_));break}case"YulFunctionCall":{const e=yield(0,i.select)(f.default.next.pointer);if(null!==e&&e.startsWith(a))break}case"YulLiteral":case"YulIdentifier":const O=a.replace(/\/[^/]*$/,""),L=yield(0,i.select)(f.default.current.root),I=y.default.get(L,O);if(a!==O+"/value"||"YulVariableDeclaration"!==I.nodeType)break;t=I,a=O;case"YulVariableDeclaration":{const e=yield(0,i.select)(f.default.current.sourceIndex),n=(0,o.makePath)(e,a);v("sourceAndPointer: %s",n),_={};let d=r;for(let e=t.variables.length-1;e>=0;e--){const t=`${n}/variables/${e}`,r=(0,o.makeAssignment)({compilationId:g,internalFor:b,astRef:t,stackframe:s,modifierDepth:u?l:null},{location:"stack",from:d,to:d});_[r.id]=r,d--}yield(0,i.put)(c.assign(_));break}case"YulTypedName":{const e=yield(0,i.select)(f.default.current.sourceIndex),t=(0,o.makePath)(e,a),n=(0,o.makeAssignment)({compilationId:g,internalFor:b,astRef:t,stackframe:s,modifierDepth:u?l:null},{location:"stack",from:r,to:r});yield(0,i.put)(c.assign({[n.id]:n}));break}case"IndexAccess":{v("Index access case"),_=(0,n.default)({},T,A(g,b,t,e,s,l,u));const r=t.baseExpression;if("bytes"===h.Ast.Utils.typeClass(r)||"array"===h.Ast.Utils.typeClass(r)&&(h.Ast.Utils.isReference(t)?"storage"!==h.Ast.Utils.referenceType(r):!h.Ast.Utils.isMapping(t))){v("Index case bailed out early"),v("typeClass %s",h.Ast.Utils.typeClass(r)),v("referenceType %s",h.Ast.Utils.referenceType(r)),v("isReference(node) %o",h.Ast.Utils.isReference(t)),yield(0,i.put)(c.assign(_));break}const a=yield(0,i.select)(f.default.current.allocations.state),p=yield(0,i.select)(f.default.proc.assignments),y=R(g,b,r,p,a,s,l,u);if(null===y){v("bailed out due to failed path"),yield(0,i.put)(c.assign(_));break}const S=yield(0,i.select)(f.default.current.scopes.inlined);let C=h.Ast.Utils.keyDefinition(r,S),O=yield*function*(e,t){const r=yield*function*(e,t){const r=yield(0,i.select)(f.default.current.scopes.inlined),n=yield(0,i.select)(f.default.current.compilationId),a=yield(0,i.select)(f.default.current.internalSourceFor),s=yield(0,i.select)(f.default.proc.assignments),c=yield(0,i.select)(f.default.current.functionDepth),l=yield(0,i.select)(f.default.current.modifierDepth),u=yield(0,i.select)(f.default.current.inModifier);for(;;){const i=e.id,d={compilationId:n,internalFor:a,astRef:i,stackframe:c,modifierDepth:u?l:null},f=(0,o.stableKeccak256)(d),p=(s[f]||{}).ref;if(h.Ast.Utils.isSimpleConstant(e))return v("about to decode simple literal"),yield*E(t,{location:"definition",definition:e},n);if(p){let r;return r=h.Ast.Utils.isReference(e)?h.Ast.Utils.spliceLocation(t,h.Ast.Utils.referenceType(e)):t,v("about to decode"),yield*E(r,p,n)}if(e.referencedDeclaration&&r[e.referencedDeclaration]){v("referencedDeclaration %d",e.referencedDeclaration);let a=r[e.referencedDeclaration].definition;if(v("indexConstantDeclaration %O",a),a.constant){let e=a.value;return h.Ast.Utils.isSimpleConstant(e)?(v("about to decode simple constant"),yield*E(t,{location:"definition",definition:a.value},n)):null}return null}if("typeConversion"===e.kind)e=e.arguments[0];else{if("UnaryOperation"!==e.nodeType||"+"!==e.operator)return null;e=e.subExpression}}}(e,t);return r?h.Conversion.cleanBool(r):r}(t.indexExpression,C);if(v("index value %O",O),v("keyDefinition %o",C),null!=O&&O.value){let e={path:y};switch(h.Ast.Utils.typeClass(r)){case"array":const n=yield(0,i.select)(f.default.current.compiler),a=yield(0,i.select)(f.default.info.allocations.storage),o=yield(0,i.select)(f.default.views.userDefinedTypes);e.hashPath=h.Ast.Utils.isDynamicArray(r),e.offset=O.value.asBN.muln(h.Storage.Allocate.storageSize(h.Ast.Import.definitionToType(t,g,n),o,a).words);break;case"mapping":e.key=O,e.offset=new m.default(0);break;default:v("unrecognized index access!")}v("slot %O",e),yield(0,i.put)(c.mapPathAndAssign(d,e,_,h.Ast.Utils.typeIdentifier(t),h.Ast.Utils.typeIdentifier(r)))}else v("failed to decode, just assigning"),yield(0,i.put)(c.assign(_));break}case"MemberAccess":{_=(0,n.default)({},T,A(g,b,t,e,s,l,u)),v("Member access case");const r=t.expression;if("struct"!==h.Ast.Utils.typeClass(r)||(h.Ast.Utils.isReference(t)?"storage"!==h.Ast.Utils.referenceType(r):!h.Ast.Utils.isMapping(t))){v("Member case bailed out early"),yield(0,i.put)(c.assign(_));break}const a=yield(0,i.select)(f.default.current.allocations.state),o=yield(0,i.select)(f.default.proc.assignments),p=R(g,b,r,o,a,s,l,u);if(null===p){v("bailed out due to failed path"),yield(0,i.put)(c.assign(_));break}let y={path:p};const m=yield(0,i.select)(f.default.current.compiler),E=h.Ast.Import.definitionToType(r,g,m),S=(yield(0,i.select)(f.default.info.allocations.storage))[E.id].members,C=(yield(0,i.select)(f.default.current.scopes.inlined))[t.referencedDeclaration].definition.name,O=S.find(e=>e.name===C);y.offset=O.pointer.range.from.slot.offset.clone(),v("slot %o",y),yield(0,i.put)(c.mapPathAndAssign(d,y,_,h.Ast.Utils.typeIdentifier(t),h.Ast.Utils.typeIdentifier(r)));break}default:if(void 0===t.id||null==t.typeDescriptions)break;v("decoding expression value %O",t.typeDescriptions),v("default case"),v("currentDepth %d node.id %d",s,t.id),_=(0,n.default)({},T,A(g,b,t,e,s,l,u)),yield(0,i.put)(c.assign(_))}}(),yield*l.signalTickSagaCompletion()}function*E(e,t,r){const n=yield(0,i.select)(f.default.views.userDefinedTypes),a=yield(0,i.select)(f.default.current.state),o=yield(0,i.select)(f.default.views.mappingKeys),s=yield(0,i.select)(f.default.info.allocations),c=yield(0,i.select)(f.default.views.contexts),l=yield(0,i.select)(f.default.current.context),u=yield(0,i.select)(f.default.current.functionsByProgramCounter);v("definition: %o"),v("ref: %o"),v("compilationId: %s",r);const d=new Uint8Array(h.Evm.Utils.WORD_SIZE),p=h.decodeVariable(e,t,{userDefinedTypes:n,state:a,mappingKeys:o,allocations:s,contexts:c,currentContext:l,internalFunctionsTable:u},r);v("beginning decoding");let y=p.next();for(;!y.done;){v("request received");let e,t=y.value;switch(t.type){case"storage":e=d;break;case"code":e=yield*T(t.address);break;default:v("unrecognized request type!")}v("sending response"),y=p.next(e)}return v("done decoding"),v("decoded value: %O",y.value),y.value}function*T(e){const t=new Uint8Array,r=yield(0,i.select)(f.default.views.blockNumber),n=yield(0,i.select)(f.default.views.instances);if(e in n)return n[e];if(e===h.Evm.Utils.ZERO_ADDRESS)return t;{v("fetching binary");let t=(yield*d.obtainBinaries([e],r))[0];return v("adding instance"),yield*u.addInstance(e,t),h.Conversion.toBytes(t)}}function A(e,t,r,n,a,i,s){let c,l=n.length-1;try{c=h.Stack.Read.readStack({location:"stack",from:l-h.Ast.Utils.stackSize(r)+1,to:l},{stack:n,storage:{}})}catch(e){c=void 0}let u=(0,o.makeAssignment)({compilationId:e,internalFor:t,astRef:r.id,stackframe:a,modifierDepth:s?i:null},{location:"stackliteral",literal:c});return{[u.id]:u}}function S(e,t,r,n,a,i=0,s=!1){let c=r.slice().reverse();v("reverseParameters %o",r);let l=n,u={};for(let r of c){let n=h.Ast.Utils.stackSize(r),c={location:"stack",from:l-n+1,to:l},d=(0,o.makeAssignment)({compilationId:e,internalFor:t,astRef:r.id,stackframe:a,modifierDepth:s?i:null},c);u[d.id]=d,l-=n}return u}function R(e,t,r,n,a,i,s,c){const l=(0,o.stableKeccak256)({compilationId:e,internalFor:t,astRef:r.id,stackframe:i,modifierDepth:c?s:null});v("astId: %d",r.id),v("stackframe: %d",i),v("fullId: %s",l),v("currentAssignments: %O",n);const u=n[l];if(u){return{offset:h.Conversion.toBN(u.ref.literal)}}const d=r.referencedDeclaration;if(null!=d){const e=a[d];if(e&&"storage"===e.pointer.location)return e.pointer.range.from.slot}return null}function*C(){yield(0,i.takeEvery)(s.TICK,_)}t.default=(0,o.prefixName)("data",C)},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.start=function(e,t){return{type:n,provider:e,txHash:t}},t.loadTransaction=function(e){return{type:a,txHash:e}},t.interrupt=function(){return{type:i}},t.unloadTransaction=function(){return{type:o}},t.ready=function(){return{type:s}},t.wait=function(){return{type:c}},t.error=function(e){return{type:l,error:e}},t.recordContracts=function(e,t){return{type:u,contexts:e,sources:t}},t.saveTransaction=function(e){return{type:d,transaction:e}},t.saveReceipt=function(e){return{type:f,receipt:e}},t.saveBlock=function(e){return{type:p,block:e}},t.setLightMode=function(){return{type:y}},t.setFullMode=function(){return{type:h}},t.startFullMode=function(){return{type:m}},t.addCompilations=function(e,t){return{type:g,sources:e,contexts:t}};const n=t.START="SESSION_START";const a=t.LOAD_TRANSACTION="SESSION_LOAD_TRANSACTION";const i=t.INTERRUPT="SESSION_INTERRUPT";const o=t.UNLOAD_TRANSACTION="SESSION_UNLOAD_TRANSACTION";const s=t.READY="SESSION_READY";const c=t.WAIT="SESSION_WAIT";const l=t.ERROR="SESSION_ERROR";const u=t.RECORD_CONTRACTS="SESSION_RECORD_CONTRACTS";const d=t.SAVE_TRANSACTION="SESSION_SAVE_TRANSACTION";const f=t.SAVE_RECEIPT="SESSION_SAVE_RECEIPT";const p=t.SAVE_BLOCK="SESSION_SAVE_BLOCK";const y=t.SET_LIGHT_MODE="SESSION_SET_LIGHT_MODE";const h=t.SET_FULL_MODE="SESSION_SET_FULL_MODE";const m=t.START_FULL_MODE="SESSION_START_FULL_MODE";const g=t.ADD_COMPILATIONS="SESSION_ADD_COMPILATIONS"},function(e,t){e.exports=require("babel-runtime/core-js/object/values")},function(e,t){e.exports=require("json-pointer")},function(e,t){e.exports=require("bn.js")},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=p(r(2)),a=p(r(0)),i=r(4),o=p(r(5)),s=p(r(8)),c=p(r(9)),l=p(r(20)),u=p(r(65)),d=r(1),f=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t}(r(3));function p(e){return e&&e.__esModule?e:{default:e}}const y=(0,a.default)("debugger:stacktrace:selectors"),h=e=>e;function m(e,t,r,a){let i=e.map(e=>e.calledFromLocation);i.shift(),i.push(t),y("locations: %O",i);const o=e.map(({functionName:e,contractName:t,address:r,type:n})=>({functionName:e,contractName:t,address:r,type:n}));y("names: %O",o);let s=(0,u.default)(i,o,(e,t)=>(0,n.default)({},t,{location:e}));return null!==r&&(s[s.length-1].status=r),void 0!==a&&(void 0!==a.Error?s[0].message=a.Error:void 0!==a.Panic?s[0].panic=a.Panic:void 0!==a.custom&&(s[0].custom=a.custom)),s}function g(e){return{location:{source:(0,i.createLeaf)([e.source],h),sourceRange:(0,i.createLeaf)([e.sourceRange],h),node:(0,i.createLeaf)([e.node],h),pointer:(0,i.createLeaf)([e.pointer],h)},strippedLocation:(0,i.createLeaf)(["./location/source","./location/sourceRange","./location/node"],({id:e,sourcePath:t,internal:r},n,a)=>({source:{id:e,sourcePath:t,internal:r},sourceRange:n,node:a?{id:a.id}:null})),contractNode:(0,i.createLeaf)(["./location/source","./location/pointer"],({ast:e},t)=>t?l.default.get(e,t.replace(/\/nodes\/\d+$/,"")):e)}}let b=(0,i.createSelectorTree)({state:e=>e.stacktrace,current:(0,n.default)({callstack:(0,i.createLeaf)(["/state"],e=>e.proc.callstack),returnCounter:(0,i.createLeaf)(["/state"],e=>e.proc.returnCounter),lastPosition:(0,i.createLeaf)(["/state"],e=>e.proc.lastPosition),innerReturnPosition:(0,i.createLeaf)(["/state"],e=>e.proc.innerReturnPosition),innerReturnStatus:(0,i.createLeaf)(["/state"],e=>e.proc.innerReturnStatus),innerErrorIndex:(0,i.createLeaf)(["/state"],e=>e.proc.innerErrorIndex)},g(c.default.current),{index:(0,i.createLeaf)([o.default.index],h),updateIndex:(0,i.createLeaf)(["./returnCounter",o.default.stepsRemaining,"./returnStatus"],(e,t,r)=>0===e&&t>1&&!r),willJumpIn:(0,i.createLeaf)([c.default.current.willJump,c.default.current.jumpDirection],(e,t)=>e&&"i"===t),willJumpOut:(0,i.createLeaf)([c.default.current.willJump,c.default.current.jumpDirection],(e,t)=>e&&"o"===t),willCall:(0,i.createLeaf)([c.default.current.willCall],h),context:(0,i.createLeaf)([s.default.current.context],h),callContext:(0,i.createLeaf)([s.default.current.step.callContext],h),willReturn:(0,i.createLeaf)([c.default.current.willReturn],h),returnStatus:(0,i.createLeaf)([s.default.current.step.returnStatus],h),address:(0,i.createLeaf)([s.default.current.call],e=>e.storageAddress),callAddress:(0,i.createLeaf)([s.default.current.step.isCall,s.default.current.step.isCreate,s.default.current.step.callAddress,s.default.current.step.createdAddress],(e,t,r,n)=>e?r:t?n!==f.Evm.Utils.ZERO_ADDRESS?n:void 0:null),revertString:(0,i.createLeaf)([s.default.current.step.returnValue],e=>{let t=f.decodeRevert(f.Conversion.toBytes(e));if(1!==t.length||"revert"!==t[0].kind)return 0===t.length?{custom:!0}:void 0;{const e=t[0];switch(e.abi.name){case"Error":const t=e.arguments[0].value.value;switch(t.kind){case"valid":return{Error:t.asString};case"malformed":return{Error:Buffer.from(t.asHex.slice(2),"hex").toString()}}case"Panic":return{Panic:e.arguments[0].value.value.asBN};default:return}}}),positionWillChange:(0,i.createLeaf)(["/next/location","/current/location","./lastPosition"],(e,t,r)=>{let n=void 0===t.source.id||t.source.internal?r:t;return Boolean(n)&&Boolean(e.source)&&void 0!==e.source.id&&!e.source.internal&&(e.source.id!==n.source.id||e.sourceRange.start!==n.sourceRange.start||e.sourceRange.length!==n.sourceRange.length)}),finalReport:(0,i.createLeaf)(["./callstack","./innerReturnPosition","./innerReturnStatus","./revertString"],m),report:(0,i.createLeaf)(["./callstack","./returnCounter","./lastPosition","/current/strippedLocation"],(e,t,r,n)=>m((0,d.popNWhere)(e,t,e=>"external"===e.type),n||r,null,void 0))}),next:(0,n.default)({},g(c.default.next))});t.default=b},function(e,t){e.exports=require("fs")},function(e,t){e.exports=require("babel-runtime/helpers/asyncToGenerator")},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.advance=function(e){return{type:n,count:e}},t.stepNext=function(){return{type:a}},t.stepOver=function(){return{type:i}},t.stepInto=function(){return{type:o}},t.stepOut=function(){return{type:s}},t.reset=function(){return{type:c}},t.interrupt=function(){return{type:l}},t.continueUntilBreakpoint=function(e){return{type:u,breakpoints:e}},t.addBreakpoint=function(e){return{type:d,breakpoint:e}},t.removeBreakpoint=function(e){return{type:f,breakpoint:e}},t.removeAllBreakpoints=function(){return{type:p}},t.setInternalStepping=function(e){return{type:y,status:e}},t.startStepping=function(){return{type:h}},t.doneStepping=function(){return{type:m}};const n=t.ADVANCE="CONTROLLER_ADVANCE";const a=t.STEP_NEXT="CONTROLLER_STEP_NEXT";const i=t.STEP_OVER="CONTROLLER_STEP_OVER";const o=t.STEP_INTO="CONTROLLER_STEP_INTO";const s=t.STEP_OUT="CONTROLLER_STEP_OUT";const c=t.RESET="CONTROLLER_RESET";const l=t.INTERRUPT="CONTROLLER_INTERRUPT";const u=t.CONTINUE="CONTROLLER_CONTINUE";const d=t.ADD_BREAKPOINT="CONTROLLER_ADD_BREAKPOINT";const f=t.REMOVE_BREAKPOINT="CONTROLLER_REMOVE_BREAKPOINT";const p=t.REMOVE_ALL_BREAKPOINTS="CONTROLLER_REMOVE_ALL_BREAKPOINTS";const y=t.SET_INTERNAL_STEPPING="CONTROLLER_SET_INTERNAL_STEPPING";const h=t.START_STEPPING="CONTROLLER_START_STEPPING";const m=t.DONE_STEPPING="CONTROLLER_DONE_STEPPING"},function(e,t){e.exports=require("babel-runtime/core-js/object/keys")},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=d(r(2)),a=d(r(0)),i=r(4),o=d(r(16)),s=d(r(8)),c=d(r(5)),l=d(r(9)),u=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t}(r(3));function d(e){return e&&e.__esModule?e:{default:e}}(0,a.default)("debugger:txlog:selectors");const f=e=>e;function p(e){return{source:(0,i.createLeaf)([e.source],f),astNode:(0,i.createLeaf)([e.node],f),inInternalSourceOrYul:(0,i.createLeaf)(["./source","./astNode"],(e,t)=>!t||e.internal||t.nodeType.startsWith("Yul")||"ContractDefinition"===t.nodeType)}}let y=(0,i.createSelectorTree)({state:e=>e.txlog,proc:{transactionLog:(0,i.createLeaf)(["/state"],e=>e.proc.transactionLog.byPointer)},transaction:{origin:(0,i.createLeaf)([s.default.transaction.globals.tx],e=>e.origin),initialCall:(0,i.createLeaf)(["/state"],e=>e.transaction.initialCall),absorbFirstInternalCall:(0,i.createLeaf)([l.default.transaction.bottomStackframeRequiresPhantomFrame],f)},current:(0,n.default)({},p(l.default.current),{state:(0,i.createLeaf)([s.default.current.state],f),pointer:(0,i.createLeaf)(["/state"],e=>e.proc.currentNodePointer),pointerStack:(0,i.createLeaf)(["/state"],e=>e.proc.pointerStack),node:(0,i.createLeaf)(["./pointer","/proc/transactionLog"],(e,t)=>t[e]),waitingForFunctionDefinition:(0,i.createLeaf)(["./node"],e=>("callinternal"===e.type||"callexternal"===e.type)&&e.waitingForFunctionDefinition),waitingForInternalCallToAbsorb:(0,i.createLeaf)(["./node"],e=>"callexternal"===e.type&&e.absorbNextInternalCall),nextCallPointer:(0,i.createLeaf)(["./pointer","./node"],(e,t)=>`${e}/actions/${t.actions.length}`),internalReturnPointer:(0,i.createLeaf)(["./pointer","./node"],(e,t)=>"callinternal"===t.type?e.replace(/\/actions\/\d+$/,""):e),externalReturnPointer:(0,i.createLeaf)(["./pointerStack"],e=>e[e.length-1].replace(/\/actions\/\d+$/,"")),context:(0,i.createLeaf)([o.default.current.context],f),call:(0,i.createLeaf)([s.default.current.call],f),contract:(0,i.createLeaf)([o.default.current.contract],f),isSourceRangeFinal:(0,i.createLeaf)([l.default.current.isSourceRangeFinal],f),onFunctionDefinition:(0,i.createLeaf)(["./astNode","./isSourceRangeFinal","/next/inInternalSourceOrYul",c.default.stepsRemaining],(e,t,r,n)=>(t||n<=2)&&e&&"FunctionDefinition"===e.nodeType&&!r),currentFunctionIsAsExpected:(0,i.createLeaf)(["./node",o.default.current.function,o.default.current.contract],(e,t,r)=>t&&("ContractDefinition"===t.nodeType||"ModifierDefinition"===t.nodeType||"FunctionDefinition"===t.nodeType&&t.name===e.functionName&&("callexternal"===e.kind||r&&r.name===e.contractName))),compilationId:(0,i.createLeaf)([o.default.current.compilationId],f),isJump:(0,i.createLeaf)([s.default.current.step.isJump],f),jumpDirection:(0,i.createLeaf)([l.default.current.jumpDirection],f),isCall:(0,i.createLeaf)([s.default.current.step.isCall],f),isDelegateCallBroad:(0,i.createLeaf)([s.default.current.step.isDelegateCallBroad],f),isCreate:(0,i.createLeaf)([s.default.current.step.isCreate],f),isInstantCallOrCreate:(0,i.createLeaf)([s.default.current.step.isInstantCallOrCreate],f),isHalting:(0,i.createLeaf)([s.default.current.step.isHalting],f),returnStatus:(0,i.createLeaf)([s.default.current.step.returnStatus],f),callValue:(0,i.createLeaf)([s.default.current.step.callValue],f),callAddress:(0,i.createLeaf)([s.default.current.step.callAddress],f),callContext:(0,i.createLeaf)([o.default.current.callContext],f),absorbNextInternalCall:(0,i.createLeaf)([l.default.current.callRequiresPhantomFrame],f),callData:(0,i.createLeaf)([s.default.current.step.callData],f),createBinary:(0,i.createLeaf)([s.default.current.step.createBinary],f),createValue:(0,i.createLeaf)([s.default.current.step.createValue],f),createdAddress:(0,i.createLeaf)([s.default.current.step.createdAddress],f),salt:(0,i.createLeaf)([s.default.current.step.salt],f),isSelfDestruct:(0,i.createLeaf)([s.default.current.step.isSelfDestruct],f),beneficiary:(0,i.createLeaf)([s.default.current.step.beneficiary],f),returnData:(0,i.createLeaf)([s.default.current.step.returnValue],f),inputParameterAllocations:(0,i.createLeaf)(["./astNode","./state"],(e,{stack:t})=>e&&"FunctionDefinition"===e.nodeType?h(e.parameters.parameters,t.length-1):null),outputParameterAllocations:(0,i.createLeaf)(["./astNode","./state"],(e,{stack:t})=>e&&"FunctionDefinition"===e.nodeType?h(e.returnParameters.parameters,t.length-2):null)}),next:(0,n.default)({},p(l.default.next)),views:{transactionLog:(0,i.createLeaf)(["/proc/transactionLog"],e=>{const t=r=>r.actions?(0,n.default)({},r,{actions:r.actions.map(r=>t(e[r]))}):r;return t(e[""])})}});function h(e,t){const r=e.slice().reverse();let n=[],a=t;for(let e of r){const t=u.Ast.Utils.stackSize(e),r={location:"stack",from:a-t+1,to:a};n.unshift({name:e.name?e.name:void 0,definition:e,pointer:r}),a-=t}return n}t.default=y},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=u(r(11)),a=u(r(12)),i=u(r(0)),o=r(4),s=u(r(8)),c=u(r(5)),l=u(r(9));function u(e){return e&&e.__esModule?e:{default:e}}const d=(0,i.default)("debugger:session:selectors"),f=(0,o.createSelectorTree)({state:e=>e.session,info:{affectedInstances:(0,o.createLeaf)([s.default.transaction.affectedInstances,s.default.info.contexts,l.default.info.sources],(e,t,r)=>(0,a.default)({},...(0,n.default)(e).map(([n,{context:a,binary:i,creationBinary:o,creationContext:s}])=>{d("instances %O",e),d("contexts %O",t);let c=t[a];if(!c)return{[n]:{binary:i}};let{contractName:l,compilationId:u,primarySource:f}=c;d("primarySource: %o",f),d("compilationId: %s",u),d("sources: %o",r);let p,y=void 0!==f?r.byCompilationId[u].byIndex[f]:void 0;if(void 0!==o){let e=t[s];e&&(p=o.slice(e.binary.length))}return{[n]:{contractName:l,source:y,binary:i,constructorArgs:p}}})))},transaction:{_:(0,o.createLeaf)(["/state"],e=>e.transaction),receipt:(0,o.createLeaf)(["/state"],e=>e.receipt),block:(0,o.createLeaf)(["/state"],e=>e.block)},status:{readyOrError:(0,o.createLeaf)(["/state"],e=>e.ready),ready:(0,o.createLeaf)(["./readyOrError","./isError"],(e,t)=>e&&!t),waiting:(0,o.createLeaf)(["/state"],e=>!e.ready),error:(0,o.createLeaf)(["/state"],e=>e.lastLoadingError),isError:(0,o.createLeaf)(["./error"],e=>null!==e),success:(0,o.createLeaf)(["./error"],e=>null===e),errored:(0,o.createLeaf)(["./readyOrError","./isError"],(e,t)=>e&&t),loaded:(0,o.createLeaf)([c.default.loaded],e=>e),lightMode:(0,o.createLeaf)(["/state"],e=>e.lightMode)}});t.default=f},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=p(r(11)),a=p(r(2));t.addContext=function*(e){const t=e.context||(0,s.keccak256)({type:"string",value:e.binary});return y("context %O",e),yield(0,o.put)(l.addContext((0,a.default)({},e,{context:t}))),t},t.addInstance=function*(e,t){const r=(yield(0,o.select)(u.default.info.binaries.search))(t);return yield(0,o.put)(l.addInstance(e,r,t)),r},t.addAffectedInstance=function*(e,t,r){const n=yield(0,o.select)(u.default.info.binaries.search),a=n(t),i=r?n(r):null;return yield(0,o.put)(l.addAffectedInstance(e,a,t,r,i)),a},t.refreshInstances=function*(){const e=yield(0,o.select)(u.default.current.codex.instances),t=yield(0,o.select)(u.default.transaction.affectedInstances);for(let[t,{binary:r}]of(0,n.default)(e)){const e=(yield(0,o.select)(u.default.info.binaries.search))(r);yield(0,o.put)(l.addInstance(t,e,r))}for(let[e,{binary:r,creationBinary:a}]of(0,n.default)(t)){const t=yield(0,o.select)(u.default.info.binaries.search),n=t(r),i=a?t(a):null;yield(0,o.put)(l.addAffectedInstance(e,n,r,a,i))}},t.begin=function*({address:e,binary:t,data:r,storageAddress:n,status:a,sender:i,value:s,gasprice:c,block:d}){yield(0,o.put)(l.saveGlobals(i,c,d)),yield(0,o.put)(l.saveStatus(a)),y("codex: %O",yield(0,o.select)(u.default.current.codex)),e?yield(0,o.put)(l.call(e,r,n,i,s)):yield(0,o.put)(l.create(t,n,i,s))},t.callstackAndCodexSaga=m,t.reset=function*(){const e=yield(0,o.select)(u.default.transaction.initialCall);yield(0,o.put)(l.reset()),yield(0,o.put)(e)},t.unload=function*(){yield(0,o.put)(l.unloadTransaction())},t.saga=g;var i=p(r(0)),o=r(6),s=r(1),c=r(13),l=f(r(36)),u=p(r(8)),d=f(r(14));function f(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t}function p(e){return e&&e.__esModule?e:{default:e}}const y=(0,i.default)("debugger:evm:sagas");function*h(){y("got TICK"),yield*m(),yield*d.signalTickSagaCompletion()}function*m(){if(yield(0,o.select)(u.default.current.step.isExceptionalHalting))y("exceptional halt!"),yield(0,o.put)(l.fail());else if(yield(0,o.select)(u.default.current.step.isInstantCallOrCreate));else if(yield(0,o.select)(u.default.current.step.isCall)){y("got call");let e=yield(0,o.select)(u.default.current.step.callAddress),t=yield(0,o.select)(u.default.current.step.callData);if(y("calling address %s",e),yield(0,o.select)(u.default.current.step.isDelegateCallStrict)){let{storageAddress:r,sender:n,value:a}=yield(0,o.select)(u.default.current.call);yield(0,o.put)(l.call(e,t,r,n,a))}else{let r=yield(0,o.select)(u.default.current.call),n=(yield(0,o.select)(u.default.current.step.isDelegateCallBroad))?r.storageAddress:e,a=r.storageAddress,i=yield(0,o.select)(u.default.current.step.callValue);yield(0,o.put)(l.call(e,t,n,a,i))}}else if(yield(0,o.select)(u.default.current.step.isCreate)){y("got create");let e=yield(0,o.select)(u.default.current.step.createBinary),t=yield(0,o.select)(u.default.current.step.createdAddress),r=yield(0,o.select)(u.default.current.step.createValue),n=(yield(0,o.select)(u.default.current.call)).storageAddress;yield(0,o.put)(l.create(e,t,n,r))}else if(yield(0,o.select)(u.default.current.step.isNormalHalting)){y("got return");let{binary:e,storageAddress:t}=yield(0,o.select)(u.default.current.call);if(e){let e=yield(0,o.select)(u.default.current.step.returnValue),r=(yield(0,o.select)(u.default.info.binaries.search))(e);yield(0,o.put)(l.returnCreate(t,e,r))}else yield(0,o.put)(l.returnCall())}else if(yield(0,o.select)(u.default.current.step.isStore)){let e=(yield(0,o.select)(u.default.current.call)).storageAddress,t=yield(0,o.select)(u.default.current.step.storageAffected),r=yield(0,o.select)(u.default.current.step.valueStored);yield(0,o.put)(l.store(e,t,r))}else if(yield(0,o.select)(u.default.current.step.isLoad)){let e=(yield(0,o.select)(u.default.current.call)).storageAddress,t=yield(0,o.select)(u.default.current.step.storageAffected),r=yield(0,o.select)(u.default.current.step.valueLoaded);yield(0,o.put)(l.load(e,t,r))}}function*g(){yield(0,o.takeEvery)(c.TICK,h)}t.default=(0,s.prefixName)("evm",g)},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=d(r(2)),a=d(r(0)),i=r(4),o=r(1),s=d(r(8)),c=d(r(9)),l=d(r(16)),u=d(r(5));function d(e){return e&&e.__esModule?e:{default:e}}const f=(0,a.default)("debugger:controller:selectors"),p=e=>e;function y(e,t,r,n){let a=r+n;return e(r,n).some(({range:e,node:t})=>function(e){return"InlineAssembly"===e.nodeType&&!e.AST}(t)||r<=e[0]&&e[0]<a&&!(0,o.isSkippedNodeType)(t))}const h=(0,i.createSelectorTree)({state:e=>e.controller,current:{functionDepth:(0,i.createLeaf)([c.default.current.functionDepth],p),executionContext:(0,i.createLeaf)([s.default.current.call],p),willJump:(0,i.createLeaf)([s.default.current.step.isJump],p),location:{sourceRange:(0,i.createLeaf)([c.default.current.sourceRange,"/current/trace/loaded"],(e,t)=>t?e:null),source:(0,i.createLeaf)([c.default.current.source,"/current/trace/loaded"],(e,t)=>t?e:null),node:(0,i.createLeaf)([c.default.current.node,"/current/trace/loaded"],(e,t)=>t?e:null),astRef:(0,i.createLeaf)([l.default.current.astRef],p),isMultiline:(0,i.createLeaf)([c.default.current.isMultiline,"/current/trace/loaded"],(e,t)=>!!t&&e)},trace:{finished:(0,i.createLeaf)([u.default.finished],p),loaded:(0,i.createLeaf)([u.default.loaded],p)}},breakpoints:{_:(0,i.createLeaf)(["/state"],e=>e.breakpoints),resolver:(0,i.createLeaf)([c.default.views.sources,c.default.views.overlapFunctions],(e,t)=>r=>{let a;if(void 0===r.node){let i=r.line;i<0&&(i=0);const{sourceId:o}=r;f("breakpoint: %O",r),f("sources: %o",e);const{source:s,ast:c}=e[o];if(!c)return r;const l=t[o],u=s.split("\n").map(e=>e.length);let d=[0];for(let e of u)d.push(d[d.length-1]+e+1);for(f("line: %s",s.slice(d[i],d[i]+u[i]));i<u.length&&!y(l,0,d[i],u[i]);)f("incrementing"),i++;a=i>=u.length?null:(0,n.default)({},r,{line:i})}else f("node-based breakpoint"),a=r;return a})},finished:(0,i.createLeaf)(["/current/trace/finished"],e=>e),isStepping:(0,i.createLeaf)(["./state"],e=>e.isStepping),stepIntoInternalSources:(0,i.createLeaf)(["./state"],e=>e.stepIntoInternalSources)});t.default=h},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=s(r(19)),a=s(r(0)),i=r(4),o=s(r(9));function s(e){return e&&e.__esModule?e:{default:e}}(0,a.default)("debugger:ast:selectors");const c=(0,i.createSelectorTree)({views:{sources:(0,i.createLeaf)([o.default.views.sources],e=>(0,n.default)(e))}});t.default=c},function(e,t,r){e.exports=u,u.Minimatch=d;var n={sep:"/"};try{n=r(10)}catch(e){}var a=u.GLOBSTAR=d.GLOBSTAR={},i=r(86),o={"!":{open:"(?:(?!(?:",close:"))[^/]*?)"},"?":{open:"(?:",close:")?"},"+":{open:"(?:",close:")+"},"*":{open:"(?:",close:")*"},"@":{open:"(?:",close:")"}},s="().*{}+?[]^$\\!".split("").reduce((function(e,t){return e[t]=!0,e}),{});var c=/\/+/;function l(e,t){e=e||{},t=t||{};var r={};return Object.keys(t).forEach((function(e){r[e]=t[e]})),Object.keys(e).forEach((function(t){r[t]=e[t]})),r}function u(e,t,r){if("string"!=typeof t)throw new TypeError("glob pattern string required");return r||(r={}),!(!r.nocomment&&"#"===t.charAt(0))&&(""===t.trim()?""===e:new d(t,r).match(e))}function d(e,t){if(!(this instanceof d))return new d(e,t);if("string"!=typeof e)throw new TypeError("glob pattern string required");t||(t={}),e=e.trim(),"/"!==n.sep&&(e=e.split(n.sep).join("/")),this.options=t,this.set=[],this.pattern=e,this.regexp=null,this.negate=!1,this.comment=!1,this.empty=!1,this.make()}function f(e,t){if(t||(t=this instanceof d?this.options:{}),void 0===(e=void 0===e?this.pattern:e))throw new TypeError("undefined pattern");return t.nobrace||!e.match(/\{.*\}/)?[e]:i(e)}u.filter=function(e,t){return t=t||{},function(r,n,a){return u(r,e,t)}},u.defaults=function(e){if(!e||!Object.keys(e).length)return u;var t=u,r=function(r,n,a){return t.minimatch(r,n,l(e,a))};return r.Minimatch=function(r,n){return new t.Minimatch(r,l(e,n))},r},d.defaults=function(e){return e&&Object.keys(e).length?u.defaults(e).Minimatch:d},d.prototype.debug=function(){},d.prototype.make=function(){if(this._made)return;var e=this.pattern,t=this.options;if(!t.nocomment&&"#"===e.charAt(0))return void(this.comment=!0);if(!e)return void(this.empty=!0);this.parseNegate();var r=this.globSet=this.braceExpand();t.debug&&(this.debug=console.error);this.debug(this.pattern,r),r=this.globParts=r.map((function(e){return e.split(c)})),this.debug(this.pattern,r),r=r.map((function(e,t,r){return e.map(this.parse,this)}),this),this.debug(this.pattern,r),r=r.filter((function(e){return-1===e.indexOf(!1)})),this.debug(this.pattern,r),this.set=r},d.prototype.parseNegate=function(){var e=this.pattern,t=!1,r=this.options,n=0;if(r.nonegate)return;for(var a=0,i=e.length;a<i&&"!"===e.charAt(a);a++)t=!t,n++;n&&(this.pattern=e.substr(n));this.negate=t},u.braceExpand=function(e,t){return f(e,t)},d.prototype.braceExpand=f,d.prototype.parse=function(e,t){if(e.length>65536)throw new TypeError("pattern is too long");var r=this.options;if(!r.noglobstar&&"**"===e)return a;if(""===e)return"";var n,i="",c=!!r.nocase,l=!1,u=[],d=[],f=!1,y=-1,h=-1,m="."===e.charAt(0)?"":r.dot?"(?!(?:^|\\/)\\.{1,2}(?:$|\\/))":"(?!\\.)",g=this;function b(){if(n){switch(n){case"*":i+="[^/]*?",c=!0;break;case"?":i+="[^/]",c=!0;break;default:i+="\\"+n}g.debug("clearStateChar %j %j",n,i),n=!1}}for(var v,_=0,E=e.length;_<E&&(v=e.charAt(_));_++)if(this.debug("%s\t%s %s %j",e,_,i,v),l&&s[v])i+="\\"+v,l=!1;else switch(v){case"/":return!1;case"\\":b(),l=!0;continue;case"?":case"*":case"+":case"@":case"!":if(this.debug("%s\t%s %s %j <-- stateChar",e,_,i,v),f){this.debug("  in class"),"!"===v&&_===h+1&&(v="^"),i+=v;continue}g.debug("call clearStateChar %j",n),b(),n=v,r.noext&&b();continue;case"(":if(f){i+="(";continue}if(!n){i+="\\(";continue}u.push({type:n,start:_-1,reStart:i.length,open:o[n].open,close:o[n].close}),i+="!"===n?"(?:(?!(?:":"(?:",this.debug("plType %j %j",n,i),n=!1;continue;case")":if(f||!u.length){i+="\\)";continue}b(),c=!0;var T=u.pop();i+=T.close,"!"===T.type&&d.push(T),T.reEnd=i.length;continue;case"|":if(f||!u.length||l){i+="\\|",l=!1;continue}b(),i+="|";continue;case"[":if(b(),f){i+="\\"+v;continue}f=!0,h=_,y=i.length,i+=v;continue;case"]":if(_===h+1||!f){i+="\\"+v,l=!1;continue}if(f){var A=e.substring(h+1,_);try{RegExp("["+A+"]")}catch(e){var S=this.parse(A,p);i=i.substr(0,y)+"\\["+S[0]+"\\]",c=c||S[1],f=!1;continue}}c=!0,f=!1,i+=v;continue;default:b(),l?l=!1:!s[v]||"^"===v&&f||(i+="\\"),i+=v}f&&(A=e.substr(h+1),S=this.parse(A,p),i=i.substr(0,y)+"\\["+S[0],c=c||S[1]);for(T=u.pop();T;T=u.pop()){var R=i.slice(T.reStart+T.open.length);this.debug("setting tail",i,T),R=R.replace(/((?:\\{2}){0,64})(\\?)\|/g,(function(e,t,r){return r||(r="\\"),t+t+r+"|"})),this.debug("tail=%j\n   %s",R,R,T,i);var C="*"===T.type?"[^/]*?":"?"===T.type?"[^/]":"\\"+T.type;c=!0,i=i.slice(0,T.reStart)+C+"\\("+R}b(),l&&(i+="\\\\");var O=!1;switch(i.charAt(0)){case".":case"[":case"(":O=!0}for(var L=d.length-1;L>-1;L--){var I=d[L],N=i.slice(0,I.reStart),x=i.slice(I.reStart,I.reEnd-8),w=i.slice(I.reEnd-8,I.reEnd),D=i.slice(I.reEnd);w+=D;var k=N.split("(").length-1,P=D;for(_=0;_<k;_++)P=P.replace(/\)[+*?]?/,"");var M="";""===(D=P)&&t!==p&&(M="$"),i=N+x+D+M+w}""!==i&&c&&(i="(?=.)"+i);O&&(i=m+i);if(t===p)return[i,c];if(!c)return function(e){return e.replace(/\\(.)/g,"$1")}(e);var U=r.nocase?"i":"";try{var j=new RegExp("^"+i+"$",U)}catch(e){return new RegExp("$.")}return j._glob=e,j._src=i,j};var p={};u.makeRe=function(e,t){return new d(e,t||{}).makeRe()},d.prototype.makeRe=function(){if(this.regexp||!1===this.regexp)return this.regexp;var e=this.set;if(!e.length)return this.regexp=!1,this.regexp;var t=this.options,r=t.noglobstar?"[^/]*?":t.dot?"(?:(?!(?:\\/|^)(?:\\.{1,2})($|\\/)).)*?":"(?:(?!(?:\\/|^)\\.).)*?",n=t.nocase?"i":"",i=e.map((function(e){return e.map((function(e){return e===a?r:"string"==typeof e?function(e){return e.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&")}(e):e._src})).join("\\/")})).join("|");i="^(?:"+i+")$",this.negate&&(i="^(?!"+i+").*$");try{this.regexp=new RegExp(i,n)}catch(e){this.regexp=!1}return this.regexp},u.match=function(e,t,r){var n=new d(t,r=r||{});return e=e.filter((function(e){return n.match(e)})),n.options.nonull&&!e.length&&e.push(t),e},d.prototype.match=function(e,t){if(this.debug("match",e,this.pattern),this.comment)return!1;if(this.empty)return""===e;if("/"===e&&t)return!0;var r=this.options;"/"!==n.sep&&(e=e.split(n.sep).join("/"));e=e.split(c),this.debug(this.pattern,"split",e);var a,i,o=this.set;for(this.debug(this.pattern,"set",o),i=e.length-1;i>=0&&!(a=e[i]);i--);for(i=0;i<o.length;i++){var s=o[i],l=e;if(r.matchBase&&1===s.length&&(l=[a]),this.matchOne(l,s,t))return!!r.flipNegate||!this.negate}return!r.flipNegate&&this.negate},d.prototype.matchOne=function(e,t,r){var n=this.options;this.debug("matchOne",{this:this,file:e,pattern:t}),this.debug("matchOne",e.length,t.length);for(var i=0,o=0,s=e.length,c=t.length;i<s&&o<c;i++,o++){this.debug("matchOne loop");var l,u=t[o],d=e[i];if(this.debug(t,u,d),!1===u)return!1;if(u===a){this.debug("GLOBSTAR",[t,u,d]);var f=i,p=o+1;if(p===c){for(this.debug("** at the end");i<s;i++)if("."===e[i]||".."===e[i]||!n.dot&&"."===e[i].charAt(0))return!1;return!0}for(;f<s;){var y=e[f];if(this.debug("\nglobstar while",e,f,t,p,y),this.matchOne(e.slice(f),t.slice(p),r))return this.debug("globstar found match!",f,s,y),!0;if("."===y||".."===y||!n.dot&&"."===y.charAt(0)){this.debug("dot detected!",e,f,t,p);break}this.debug("globstar swallow a segment, and continue"),f++}return!(!r||(this.debug("\n>>> no match, partial?",e,f,t,p),f!==s))}if("string"==typeof u?(l=n.nocase?d.toLowerCase()===u.toLowerCase():d===u,this.debug("string match",u,d,l)):(l=d.match(u),this.debug("pattern match",u,d,l)),!l)return!1}if(i===s&&o===c)return!0;if(i===s)return r;if(o===c)return i===s-1&&""===e[i];throw new Error("wtf?")}},function(e,t,r){"use strict";function n(e){return"/"===e.charAt(0)}function a(e){var t=/^([a-zA-Z]:|[\\\/]{2}[^\\\/]+[\\\/]+[^\\\/]+)?([\\\/])?([\s\S]*?)$/.exec(e),r=t[1]||"",n=Boolean(r&&":"!==r.charAt(1));return Boolean(t[2]||n)}e.exports="win32"===process.platform?a:n,e.exports.posix=n,e.exports.win32=a},function(e,t){e.exports=require("semver")},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.scope=function(e,t,r,a,i){return{type:n,id:e,pointer:t,parentId:r,sourceIndex:a,sourceId:i}},t.declare=function(e,t,r,n){return{type:a,name:e,astRef:t,scopeAstRef:r,sourceId:n}},t.assign=function(e){return{type:i,assignments:e}},t.mapPathAndAssign=function(e,t,r,n,a){return{type:o,address:e,slot:t,assignments:r,typeIdentifier:n,parentType:a}},t.reset=function(){return{type:s}},t.defineType=function(e,t){return{type:c,node:e,sourceId:t}},t.defineTaggedOutput=function(e,t){return{type:l,node:e,sourceId:t}},t.allocate=function(e,t,r,n,a,i){return{type:u,storage:e,memory:t,abi:r,calldata:n,returndata:a,state:i}};const n=t.SCOPE="DATA_SCOPE";const a=t.DECLARE="DATA_DECLARE_VARIABLE";const i=t.ASSIGN="DATA_ASSIGN";const o=t.MAP_PATH_AND_ASSIGN="DATA_MAP_PATH_AND_ASSIGN";const s=t.RESET="DATA_RESET";const c=t.DEFINE_TYPE="DATA_DEFINE_TYPE";const l=t.DEFINE_TAGGED_OUTPUT="DATA_DEFINE_TAGGED_OUTPUT";const u=t.ALLOCATE="DATA_ALLOCATE"},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.addContext=function({context:e,contractName:t,binary:r,sourceMap:a,primarySource:i,immutableReferences:o,compiler:s,compilationId:c,abi:l,contractId:u,contractKind:d,isConstructor:f,linearizedBaseContracts:p}){return{type:n,context:e,contractName:t,binary:r,sourceMap:a,primarySource:i,immutableReferences:o,compiler:s,compilationId:c,abi:l,contractId:u,contractKind:d,isConstructor:f,linearizedBaseContracts:p}},t.addInstance=function(e,t,r){return{type:a,address:e,context:t,binary:r}},t.addAffectedInstance=function(e,t,r,n,a){return{type:i,address:e,context:t,binary:r,creationBinary:n,creationContext:a}},t.refreshInstances=function(e,t){return{type:o,address:e,context:t}},t.saveGlobals=function(e,t,r){return{type:s,origin:e,gasprice:t,block:r}},t.saveStatus=function(e){return{type:c,status:e}},t.call=function(e,t,r,n,a){return{type:l,address:e,data:t,storageAddress:r,sender:n,value:a}},t.create=function(e,t,r,n){return{type:u,binary:e,storageAddress:t,sender:r,value:n}},t.returnCall=function(){return{type:d}},t.returnCreate=function(e,t,r){return{type:f,address:e,code:t,context:r}},t.fail=function(){return{type:p}},t.store=function(e,t,r){return{type:y,address:e,slot:t,value:r}},t.load=function(e,t,r){return{type:h,address:e,slot:t,value:r}},t.reset=function(e){return{type:m,storageAddress:e}},t.unloadTransaction=function(){return{type:g}};const n=t.ADD_CONTEXT="EVM_ADD_CONTEXT";const a=t.ADD_INSTANCE="EVM_ADD_INSTANCE";const i=t.ADD_AFFECTED_INSTANCE="EVM_ADD_AFFECTED_INSTANCE";const o=t.REFRESH_INSTANCE="EVM_REFRESH_INSTANCE";const s=t.SAVE_GLOBALS="EVM_SAVE_GLOBALS";const c=t.SAVE_STATUS="EVM_SAVE_STATUS";const l=t.CALL="EVM_CALL";const u=t.CREATE="EVM_CREATE";const d=t.RETURN_CALL="EVM_RETURN_CALL";const f=t.RETURN_CREATE="EVM_RETURN_CREATE";const p=t.FAIL="EVM_FAIL";const y=t.STORE="EVM_STORE";const h=t.LOAD="EVM_LOAD";const m=t.RESET="EVM_RESET";const g=t.UNLOAD_TRANSACTION="EVM_UNLOAD_TRANSACTION"},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=y(r(2));t.inspectTransaction=function*(e){yield(0,i.put)(s.inspect(e));let t=yield(0,i.take)([s.RECEIVE_TRACE,s.ERROR_WEB3]);var r;if(h("action %o",t),t.type!=s.RECEIVE_TRACE)return{error:t.error};r=t.trace,h("received trace");let{address:n,binary:a,data:o,storageAddress:c,status:l,sender:u,value:d,gasprice:f,block:p}=yield(0,i.take)(s.RECEIVE_CALL);return h("received call"),{trace:r,address:n,binary:a,data:o,storageAddress:c,status:l,sender:u,value:d,gasprice:f,block:p}},t.obtainBinaries=function*(e,t){let r=yield(0,i.all)(e.map(e=>(0,i.fork)(v,e)));h("requesting binaries"),yield(0,i.all)(e.map(e=>(0,i.put)(s.fetchBinary(e,t))));let n=[];return n=yield(0,i.join)(r),h("binaries %o",n),n},t.init=function*(e){yield(0,i.put)(s.init(e))},t.saga=_;var a=y(r(0)),i=r(6),o=r(1),s=p(r(67)),c=p(r(18)),l=y(r(21)),u=y(r(38)),d=p(r(3)),f=y(r(68));function p(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t}function y(e){return e&&e.__esModule?e:{default:e}}const h=(0,a.default)("debugger:web3:sagas");function m(e){return e.startsWith("0x")?e.slice(2).padStart(2*d.Evm.Utils.WORD_SIZE,"0"):e}function*g(e,{txHash:t}){var r;h("inspecting transaction");try{r=yield(0,i.apply)(e,e.getTrace,[t])}catch(e){return h("putting error"),void(yield(0,i.put)(s.error(e)))}h("got trace"),r=r.map(e=>(0,n.default)({},e,{stack:e.stack.map(m),memory:e.memory.map(m)})),yield(0,i.put)(s.receiveTrace(r));const a=yield(0,i.apply)(e,e.getTransaction,[t]);h("tx %O",a);const o=yield(0,i.apply)(e,e.getReceipt,[t]);h("receipt %O",o);const f=yield(0,i.apply)(e,e.getBlock,[a.blockNumber]);h("block %O",f);const p=yield(0,i.apply)(e,e.getChainId);yield(0,i.put)(c.saveTransaction(a)),yield(0,i.put)(c.saveReceipt(o)),yield(0,i.put)(c.saveBlock(f));let y={coinbase:f.miner,difficulty:new l.default(f.difficulty),gaslimit:new l.default(f.gasLimit),number:new l.default(f.number),timestamp:new l.default(f.timestamp),chainid:new l.default(p)};if(null!=a.to)yield(0,i.put)(s.receiveCall({address:a.to,data:a.input,storageAddress:a.to,status:o.status,sender:a.from,value:new l.default(a.value),gasprice:new l.default(a.gasPrice),block:y}));else{let e=u.default.utils.isAddress(o.contractAddress)?o.contractAddress:d.Evm.Utils.ZERO_ADDRESS;yield(0,i.put)(s.receiveCall({binary:a.input,storageAddress:e,status:o.status,sender:a.from,value:new l.default(a.value),gasprice:new l.default(a.gasPrice),block:y}))}}function*b(e,{address:t,block:r}){h("fetching binary for %s",t);let n=yield(0,i.apply)(e,e.getDeployedCode,[t,r]);h("received binary for %s",t),yield(0,i.put)(s.receiveBinary(t,n))}function*v(e){let{binary:t}=yield(0,i.take)(t=>t.type==s.RECEIVE_BINARY&&t.address==e);return h("got binary for %s",e),t}function*_(){let{provider:e}=yield(0,i.take)(s.INIT_WEB3),t=new f.default(e);yield(0,i.takeEvery)(s.INSPECT,g,t),yield(0,i.takeEvery)(s.FETCH_BINARY,b,t)}t.default=(0,o.prefixName)("web3",_)},function(e,t){e.exports=require("web3")},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=m(r(26));t.saga=v,t.reset=function*(){yield*c.reset(),yield*u.reset(),yield*d.reset(),yield*s.reset(),yield*f.reset(),yield*l.reset()};var a=m(r(0)),i=r(6),o=r(1),s=h(r(14)),c=h(r(17)),l=h(r(40)),u=h(r(29)),d=h(r(42)),f=h(r(44)),p=h(r(25)),y=m(r(30));function h(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t}function m(e){return e&&e.__esModule?e:{default:e}}const g=(0,a.default)("debugger:controller:sagas"),b={[p.ADVANCE]:_,[p.STEP_NEXT]:E,[p.STEP_OVER]:T,[p.STEP_INTO]:function*(){const e=yield(0,i.select)(y.default.current.functionDepth),t=yield(0,i.select)(y.default.current.location);let r,n,a;g("startingDepth: %d",e),g("starting source range: %O",(t||{}).sourceRange);do{yield*E(),r=yield(0,i.select)(y.default.current.functionDepth),n=yield(0,i.select)(y.default.current.location),a=yield(0,i.select)(y.default.current.trace.finished),g("currentDepth: %d",r),g("current source range: %O",(n||{}).sourceRange),g("finished: %o",a)}while(!a&&r<=e&&n.source.id===t.source.id&&n.sourceRange.lines.start.line===t.sourceRange.lines.start.line)},[p.STEP_OUT]:function*(){if(yield(0,i.select)(y.default.current.location.isMultiline))return void(yield*T());const e=yield(0,i.select)(y.default.current.functionDepth);var t,r;do{yield*E(),t=yield(0,i.select)(y.default.current.functionDepth),r=yield(0,i.select)(y.default.current.trace.finished)}while(!r&&t>=e)},[p.CONTINUE]:function*(e){let t=void 0!==e&&void 0!==e.breakpoints?e.breakpoints:yield(0,i.select)(y.default.breakpoints),r=!1,n=yield(0,i.select)(y.default.current.location),a=n.source.id,o=n.sourceRange.lines.start.line,s=n.sourceRange.start,c=n.sourceRange.start;const l=!(yield(0,i.select)(y.default.stepIntoInternalSources))&&void 0!==n.source.id&&!n.source.internal;let u=a,d=o,f=s,p=c;do{yield*_();let e=o,h=s,m=c,g=a;if(n.source.internal||(u=a,d=o,f=s,p=c),n=yield(0,i.select)(y.default.current.location),yield(0,i.select)(y.default.current.trace.finished))break;a=n.source.id,void 0!==a&&(o=n.sourceRange.lines.start.line,s=n.sourceRange.start,c=n.sourceRange.length,r=t.filter(({sourceId:t,line:r,start:n,length:i})=>void 0!==n&&void 0!==i?!(t!==a||n!==s||i!==c||a===g&&s===h&&c===m||l&&a===u&&s===f&&c===p):!(t!==a||r!==o||a===g&&o===e||l&&a===u&&o===d)).length>0)}while(!r)}};function*v(){for(;;){g("waiting for control action");let e=yield(0,i.take)((0,n.default)(b));if(!(yield(0,i.select)(y.default.current.trace.loaded)))continue;g("got control action");let t=b[e.type];yield(0,i.put)(p.startStepping()),yield(0,i.race)({exec:(0,i.call)(t,e),interrupt:(0,i.take)(p.INTERRUPT)}),yield(0,i.put)(p.doneStepping())}}function*_(e){let t=void 0!==e&&void 0!==e.count?e.count:1;for(let e=0;e<t&&!(yield(0,i.select)(y.default.current.trace.finished));e++)yield*s.advance()}function*E(){const e=yield(0,i.select)(y.default.current.location),t=yield(0,i.select)(y.default.stepIntoInternalSources);let r,n;do{yield*_(),r=yield(0,i.select)(y.default.current.location),n=yield(0,i.select)(y.default.current.trace.finished)}while(!n&&(!r||!t&&r.source.internal&&!e.source.internal||0===r.sourceRange.length||void 0===r.source.id||r.node&&(0,o.isDeliberatelySkippedNodeType)(r.node)||r.sourceRange.start===e.sourceRange.start&&r.sourceRange.length===e.sourceRange.length&&r.source.id===e.source.id))}function*T(){const e=yield(0,i.select)(y.default.current.functionDepth),t=yield(0,i.select)(y.default.current.location);var r,n,a;do{yield*E(),r=yield(0,i.select)(y.default.current.functionDepth),n=yield(0,i.select)(y.default.current.location),a=yield(0,i.select)(y.default.current.trace.finished)}while(!a&&r>=e&&(r>e||n.source.id===t.source.id&&n.sourceRange.lines.start.line===t.sourceRange.lines.start.line))}t.default=(0,o.prefixName)("controller",v)},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.reset=function*(){const e=yield(0,a.select)(d.default.transaction.initialCall);yield(0,a.put)(s.reset()),yield(0,a.put)(e)},t.unload=function*(){yield(0,a.put)(s.unloadTransaction())},t.begin=function*(){const e=yield(0,a.select)(d.default.current.pointer),t=yield(0,a.select)(d.default.current.nextCallPointer),r=yield(0,a.select)(d.default.transaction.origin);y("origin: %o",e),yield(0,a.put)(s.recordOrigin(e,r));const{address:n,binary:i,storageAddress:o,value:c,data:l}=yield(0,a.select)(d.default.current.call),f=yield(0,a.select)(d.default.current.context),p=yield*u.decodeCall(!0);if(n){const r=m(f,l,!1),i=yield(0,a.select)(d.default.transaction.absorbFirstInternalCall);y("initial call: %o %o",e,t),yield(0,a.put)(s.externalCall(e,t,n,f,c,!1,r,p,l,i))}else y("initial create: %o %o",e,t),yield(0,a.put)(s.create(e,t,o,f,c,null,p,i))},t.saga=g;var n=p(r(0)),a=r(6),i=r(1),o=f(r(3)),s=f(r(41)),c=r(13),l=f(r(14)),u=f(r(17)),d=p(r(27));function f(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t}function p(e){return e&&e.__esModule?e:{default:e}}const y=(0,n.default)("debugger:txlog:sagas");function*h(){yield*function*(){const e=yield(0,a.select)(d.default.current.pointer);if(yield(0,a.select)(d.default.current.isHalting)){const t=yield(0,a.select)(d.default.current.externalReturnPointer);if(yield(0,a.select)(d.default.current.returnStatus))if(yield(0,a.select)(d.default.current.isSelfDestruct)){const r=yield(0,a.select)(d.default.current.beneficiary);y("sd: %o %o",e,t),yield(0,a.put)(s.selfdestruct(e,t,r))}else{const r=yield*u.decodeReturnValue(),n=yield(0,a.select)(d.default.current.returnData);y("external return: %o %o",e,t),yield(0,a.put)(s.externalReturn(e,t,r,n))}else{const r=(yield*u.decodeReturnValue())[0];y("revert: %o %o",e,t),yield(0,a.put)(s.revert(e,t,r))}}else if(yield(0,a.select)(d.default.current.isJump)){const t=yield(0,a.select)(d.default.current.jumpDirection);if("i"===t){if(!(yield(0,a.select)(d.default.next.inInternalSourceOrYul)))if(yield(0,a.select)(d.default.current.waitingForInternalCallToAbsorb))y("absorbed call: %o",e),yield(0,a.put)(s.absorbedCall(e));else{const t=yield(0,a.select)(d.default.current.nextCallPointer);y("internal call: %o %o",e,t),yield(0,a.put)(s.internalCall(e,t))}}else if("o"===t){const t=yield(0,a.select)(d.default.current.inInternalSourceOrYul),r=yield(0,a.select)(d.default.current.currentFunctionIsAsExpected);if(!t&&r){const t=yield(0,a.select)(d.default.current.internalReturnPointer),r=yield(0,a.select)(d.default.current.outputParameterAllocations);if(r){const n=yield(0,a.select)(d.default.current.compilationId);let i=[];for(let e of r){let{name:t,definition:r,pointer:a}=e;t=t||void 0;const o=yield*u.decode(r,a,n);i.push({name:t,value:o})}y("internal return: %o %o",e,t),yield(0,a.put)(s.internalReturn(e,t,i))}else y("internal return: %o %o",e,t),yield(0,a.put)(s.internalReturn(e,t,void 0))}}}else if(yield(0,a.select)(d.default.current.isCall)){const t=yield(0,a.select)(d.default.current.nextCallPointer),r=yield(0,a.select)(d.default.current.callAddress),n=yield(0,a.select)(d.default.current.callValue),i=yield(0,a.select)(d.default.current.isDelegateCallBroad),o=yield(0,a.select)(d.default.current.callContext),c=yield(0,a.select)(d.default.current.callData),l=yield(0,a.select)(d.default.current.isInstantCallOrCreate),f=m(o,c,l),p=yield(0,a.select)(d.default.current.absorbNextInternalCall),h=yield*u.decodeCall();if(l){const l=yield(0,a.select)(d.default.current.returnStatus);y("instacall: %o %o",e,t),yield(0,a.put)(s.instantExternalCall(e,t,r,o,n,i,f,h,c,p,l))}else y("external call: %o %o",e,t),yield(0,a.put)(s.externalCall(e,t,r,o,n,i,f,h,c,p))}else if(yield(0,a.select)(d.default.current.isCreate)){const t=yield(0,a.select)(d.default.current.nextCallPointer),r=yield(0,a.select)(d.default.current.createdAddress),n=yield(0,a.select)(d.default.current.callContext),i=yield(0,a.select)(d.default.current.createValue),o=yield(0,a.select)(d.default.current.salt),c=yield(0,a.select)(d.default.current.isInstantCallOrCreate),l=yield(0,a.select)(d.default.current.createBinary),f=yield*u.decodeCall();if(c){const c=yield(0,a.select)(d.default.current.returnStatus);y("instacreate: %o %o",e,t),yield(0,a.put)(s.instantCreate(e,t,r,n,i,o,f,l,c))}else y("create: %o %o",e,t),yield(0,a.put)(s.create(e,t,r,n,i,o,f,l))}if((yield(0,a.select)(d.default.current.onFunctionDefinition))&&(yield(0,a.select)(d.default.current.waitingForFunctionDefinition))){y("identifying");const t=yield(0,a.select)(d.default.current.inputParameterAllocations);if(y("inputAllocations: %O",t),t){const r=yield(0,a.select)(d.default.current.astNode),n=yield(0,a.select)(d.default.current.contract),i=yield(0,a.select)(d.default.current.compilationId);let o=[];for(let e of t){let{name:t,definition:r,pointer:n}=e;const a=yield*u.decode(r,n,i);o.push({name:t,value:a})}y("identify: %o",e),yield(0,a.put)(s.identifyFunctionCall(e,r,n,o))}}}(),yield*l.signalTickSagaCompletion()}function m(e,t,r){if(e){if("library"===e.contractKind)return r?"message":"library";{const r=e.abi,n=t.slice(0,2+2*o.Evm.Utils.SELECTOR_SIZE).padEnd("00",2+2*o.Evm.Utils.SELECTOR_SIZE);if(y("selector: %s",n),r&&n in r)return"function"}}return"message"}function*g(){yield(0,a.takeEvery)(c.TICK,h)}t.default=(0,i.prefixName)("txlog",g)},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.internalCall=function(e,t){return{type:n,pointer:e,newPointer:t}},t.absorbedCall=function(e){return{type:a,pointer:e}},t.internalReturn=function(e,t,r){return{type:i,pointer:e,newPointer:t,variables:r}},t.externalCall=function(e,t,r,n,a,i,s,c,l,u){return{type:o,pointer:e,newPointer:t,address:r,context:n,value:a,isDelegate:i,kind:s,decoding:c,calldata:l,absorbNextInternalCall:u}},t.instantExternalCall=function(e,t,r,n,a,i,o,c,l,u,d){return{type:s,pointer:e,newPointer:t,address:r,context:n,value:a,isDelegate:i,kind:o,decoding:c,calldata:l,absorbNextInternalCall:u,status:d}},t.create=function(e,t,r,n,a,i,o,s){return{type:c,pointer:e,newPointer:t,address:r,context:n,value:a,salt:i,decoding:o,binary:s}},t.instantCreate=function(e,t,r,n,a,i,o,s,c){return{type:l,pointer:e,newPointer:t,address:r,context:n,value:a,salt:i,decoding:o,binary:s,status:c}},t.externalReturn=function(e,t,r,n){return{type:u,pointer:e,newPointer:t,decodings:r,returnData:n}},t.selfdestruct=function(e,t,r){return{type:d,pointer:e,newPointer:t,beneficiary:r}},t.revert=function(e,t,r){return{type:f,pointer:e,newPointer:t,error:r}},t.identifyFunctionCall=function(e,t,r,n){return{type:p,pointer:e,functionNode:t,contractNode:r,variables:n}},t.recordOrigin=function(e,t){return{type:y,pointer:e,address:t}},t.reset=function(){return{type:h}},t.unloadTransaction=function(){return{type:m}};const n=t.INTERNAL_CALL="TXLOG_INTERNAL_CALL";const a=t.ABSORBED_CALL="TXLOG_ABSORBED_CALL";const i=t.INTERNAL_RETURN="TXLOG_INTERNAL_RETURN";const o=t.EXTERNAL_CALL="TXLOG_EXTERNAL_CALL";const s=t.INSTANT_EXTERNAL_CALL="TXLOG_INSTANT_EXTERNAL_CALL";const c=t.CREATE="TXLOG_CREATE";const l=t.INSTANT_CREATE="TXLOG_INSTANT_CREATE";const u=t.EXTERNAL_RETURN="TXLOG_EXTERNAL_RETURN";const d=t.SELFDESTRUCT="TXLOG_SELFDESTRUCT";const f=t.REVERT="TXLOG_REVERT";const p=t.IDENTIFY_FUNCTION_CALL="TXLOG_IDENTIFY_FUNCTION_CALL";const y=t.RECORD_ORIGIN="TXLOG_RECORD_ORIGIN";const h=t.RESET="TXLOG_RESET";const m=t.UNLOAD_TRANSACTION="TXLOG_UNLOAD_TRANSACTION"},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.addSources=function*(e){yield(0,a.put)(o.addSources(e))},t.reset=function*(){let e=yield(0,a.select)(l.default.transaction.bottomStackframeRequiresPhantomFrame);yield(0,a.put)(o.reset(e))},t.unload=function*(){yield(0,a.put)(o.unloadTransaction())},t.begin=function*(){let e=yield(0,a.select)(l.default.transaction.bottomStackframeRequiresPhantomFrame);yield(0,a.put)(o.externalCall(e))},t.saga=y;var n=d(r(0)),a=r(6),i=r(1),o=u(r(43)),s=r(13),c=u(r(14)),l=d(r(9));function u(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t}function d(e){return e&&e.__esModule?e:{default:e}}const f=(0,n.default)("debugger:solidity:sagas");function*p(){f("got TICK"),yield*function*(){if(yield(0,a.select)(l.default.current.willReturn))yield(0,a.put)(o.externalReturn());else if(yield(0,a.select)(l.default.current.willJump)){let e=yield(0,a.select)(l.default.current.jumpDirection);f("checking guard");let t=yield(0,a.select)(l.default.current.nextFrameIsPhantom),r=yield(0,a.select)(l.default.next.source);"i"===e&&t&&void 0!==r.id?yield(0,a.put)(o.clearPhantomGuard()):yield(0,a.put)(o.jump(e))}else if(yield(0,a.select)(l.default.current.willCall)){f("checking if guard needed");let e=yield(0,a.select)(l.default.current.callRequiresPhantomFrame);yield(0,a.put)(o.externalCall(e))}}(),f("instruction: %O",yield(0,a.select)(l.default.current.instruction)),yield*c.signalTickSagaCompletion()}function*y(){yield(0,a.takeEvery)(s.TICK,p)}t.default=(0,i.prefixName)("solidity",y)},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.addSources=function(e){return{type:n,sources:e}},t.jump=function(e){return{type:a,jumpDirection:e}},t.externalCall=function(e){return{type:i,guard:e}},t.externalReturn=function(){return{type:o}},t.clearPhantomGuard=function(){return{type:s}},t.reset=function(e){return{type:c,guard:e}},t.unloadTransaction=function(){return{type:l}};const n=t.ADD_SOURCES="SOLIDITY_ADD_SOURCES";const a=t.JUMP="SOLIDITY_JUMP";const i=t.EXTERNAL_CALL="SOLIDITY_EXTERNAL_CALL";const o=t.EXTERNAL_RETURN="SOLIDITY_EXTERNAL_RETURN";const s=t.CLEAR_PHANTOM_GUARD="SOLIDITY_CLEAR_PHANTOM_GUARD";const c=t.RESET="SOLIDITY_RESET";const l=t.UNLOAD_TRANSACTION="SOLIDITY_UNLOAD_TRANSACTION"},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.reset=function*(){yield(0,a.put)(o.reset())},t.unload=function*(){yield(0,a.put)(o.unloadTransaction())},t.begin=function*(){const e=yield(0,a.select)(l.default.current.context),t=yield(0,a.select)(l.default.current.address);yield(0,a.put)(o.externalCall(null,e,t))},t.saga=y;var n=d(r(0)),a=r(6),i=r(1),o=u(r(45)),s=r(13),c=u(r(14)),l=d(r(22));function u(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t}function d(e){return e&&e.__esModule?e:{default:e}}const f=(0,n.default)("debugger:stacktrace:sagas");function*p(){yield*function*(){const e=yield(0,a.select)(l.default.current.strippedLocation),t=yield(0,a.select)(l.default.current.lastPosition),r=yield(0,a.select)(l.default.current.returnCounter);let n=!1;if(yield(0,a.select)(l.default.current.willReturn)){const r=yield(0,a.select)(l.default.current.returnStatus),i=yield(0,a.select)(l.default.current.index),s=yield(0,a.select)(l.default.current.updateIndex);f("returning!"),yield(0,a.put)(o.externalReturn(t,r,e,s?i:null)),n=!0}else r>0&&(yield(0,a.select)(l.default.current.positionWillChange))&&(f("executing!"),f("location: %o",yield(0,a.select)(l.default.next.location)),f("marked: %o",t),yield(0,a.put)(o.executeReturn(r,e)),n=!0);if((yield(0,a.select)(l.default.current.willJumpIn))&&0===r){const t=yield(0,a.select)(l.default.next.location),r=yield(0,a.select)(l.default.next.contractNode);yield(0,a.put)(o.jumpIn(e,t.node,r)),n=!0}else if((yield(0,a.select)(l.default.current.willJumpOut))&&0===r)yield(0,a.put)(o.jumpOut(e)),n=!0;else if(yield(0,a.select)(l.default.current.willCall)){const t=yield(0,a.select)(l.default.current.callContext),r=yield(0,a.select)(l.default.current.callAddress);yield(0,a.put)(o.externalCall(e,t,r)),n=!0}n||(yield(0,a.put)(o.updatePosition(e)))}(),yield*c.signalTickSagaCompletion()}function*y(){yield(0,a.takeEvery)(s.TICK,p)}t.default=(0,i.prefixName)("stacktrace",y)},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.jumpIn=function(e,t,r){return{type:n,location:e,functionNode:t,contractNode:r}},t.jumpOut=function(e){return{type:a,location:e}},t.externalCall=function(e,t,r){return{type:i,location:e,context:t,address:r}},t.externalReturn=function(e,t,r,n){return{type:o,from:e,status:t,location:r,index:n}},t.executeReturn=function(e,t){return{type:s,counter:e,location:t}},t.updatePosition=function(e){return{type:c,location:e}},t.reset=function(){return{type:l}},t.unloadTransaction=function(){return{type:u}};const n=t.JUMP_IN="STACKTRACE_JUMP_IN";const a=t.JUMP_OUT="STACKTRACE_JUMP_OUT";const i=t.EXTERNAL_CALL="STACKTRACE_EXTERNAL_CALL";const o=t.EXTERNAL_RETURN="STACKTRACE_EXTERNAL_RETURN";const s=t.EXECUTE_RETURN="STACKTRACE_EXECUTE_RETURN";const c=t.UPDATE_POSITION="STACKTRACE_UPDATE_POSITION";const l=t.RESET="STACKTRACE_RESET";const u=t.UNLOAD_TRANSACTION="STACKTRACE_UNLOAD_TRANSACTION"},function(e,t,r){e.exports=v;var n=r(23),a=r(47),i=r(32),o=(i.Minimatch,r(89)),s=r(91).EventEmitter,c=r(10),l=r(48),u=r(33),d=r(92),f=r(49),p=(f.alphasort,f.alphasorti,f.setopts),y=f.ownProp,h=r(93),m=(r(15),f.childrenIgnored),g=f.isIgnored,b=r(51);function v(e,t,r){if("function"==typeof t&&(r=t,t={}),t||(t={}),t.sync){if(r)throw new TypeError("callback provided to sync glob");return d(e,t)}return new E(e,t,r)}v.sync=d;var _=v.GlobSync=d.GlobSync;function E(e,t,r){if("function"==typeof t&&(r=t,t=null),t&&t.sync){if(r)throw new TypeError("callback provided to sync glob");return new _(e,t)}if(!(this instanceof E))return new E(e,t,r);p(this,e,t),this._didRealPath=!1;var n=this.minimatch.set.length;this.matches=new Array(n),"function"==typeof r&&(r=b(r),this.on("error",r),this.on("end",(function(e){r(null,e)})));var a=this;if(this._processing=0,this._emitQueue=[],this._processQueue=[],this.paused=!1,this.noprocess)return this;if(0===n)return o();for(var i=0;i<n;i++)this._process(this.minimatch.set[i],i,!1,o);function o(){--a._processing,a._processing<=0&&a._finish()}}v.glob=v,v.hasMagic=function(e,t){var r=function(e,t){if(null===t||"object"!=typeof t)return e;for(var r=Object.keys(t),n=r.length;n--;)e[r[n]]=t[r[n]];return e}({},t);r.noprocess=!0;var n=new E(e,r).minimatch.set;if(!e)return!1;if(n.length>1)return!0;for(var a=0;a<n[0].length;a++)if("string"!=typeof n[0][a])return!0;return!1},v.Glob=E,o(E,s),E.prototype._finish=function(){if(l(this instanceof E),!this.aborted){if(this.realpath&&!this._didRealpath)return this._realpath();f.finish(this),this.emit("end",this.found)}},E.prototype._realpath=function(){if(!this._didRealpath){this._didRealpath=!0;var e=this.matches.length;if(0===e)return this._finish();for(var t=this,r=0;r<this.matches.length;r++)this._realpathSet(r,n)}function n(){0==--e&&t._finish()}},E.prototype._realpathSet=function(e,t){var r=this.matches[e];if(!r)return t();var n=Object.keys(r),i=this,o=n.length;if(0===o)return t();var s=this.matches[e]=Object.create(null);n.forEach((function(r,n){r=i._makeAbs(r),a.realpath(r,i.realpathCache,(function(n,a){n?"stat"===n.syscall?s[r]=!0:i.emit("error",n):s[a]=!0,0==--o&&(i.matches[e]=s,t())}))}))},E.prototype._mark=function(e){return f.mark(this,e)},E.prototype._makeAbs=function(e){return f.makeAbs(this,e)},E.prototype.abort=function(){this.aborted=!0,this.emit("abort")},E.prototype.pause=function(){this.paused||(this.paused=!0,this.emit("pause"))},E.prototype.resume=function(){if(this.paused){if(this.emit("resume"),this.paused=!1,this._emitQueue.length){var e=this._emitQueue.slice(0);this._emitQueue.length=0;for(var t=0;t<e.length;t++){var r=e[t];this._emitMatch(r[0],r[1])}}if(this._processQueue.length){var n=this._processQueue.slice(0);this._processQueue.length=0;for(t=0;t<n.length;t++){var a=n[t];this._processing--,this._process(a[0],a[1],a[2],a[3])}}}},E.prototype._process=function(e,t,r,n){if(l(this instanceof E),l("function"==typeof n),!this.aborted)if(this._processing++,this.paused)this._processQueue.push([e,t,r,n]);else{for(var a,o=0;"string"==typeof e[o];)o++;switch(o){case e.length:return void this._processSimple(e.join("/"),t,n);case 0:a=null;break;default:a=e.slice(0,o).join("/")}var s,c=e.slice(o);null===a?s=".":u(a)||u(e.join("/"))?(a&&u(a)||(a="/"+a),s=a):s=a;var d=this._makeAbs(s);if(m(this,s))return n();c[0]===i.GLOBSTAR?this._processGlobStar(a,s,d,c,t,r,n):this._processReaddir(a,s,d,c,t,r,n)}},E.prototype._processReaddir=function(e,t,r,n,a,i,o){var s=this;this._readdir(r,i,(function(c,l){return s._processReaddir2(e,t,r,n,a,i,l,o)}))},E.prototype._processReaddir2=function(e,t,r,n,a,i,o,s){if(!o)return s();for(var l=n[0],u=!!this.minimatch.negate,d=l._glob,f=this.dot||"."===d.charAt(0),p=[],y=0;y<o.length;y++){if("."!==(m=o[y]).charAt(0)||f)(u&&!e?!m.match(l):m.match(l))&&p.push(m)}var h=p.length;if(0===h)return s();if(1===n.length&&!this.mark&&!this.stat){this.matches[a]||(this.matches[a]=Object.create(null));for(y=0;y<h;y++){var m=p[y];e&&(m="/"!==e?e+"/"+m:e+m),"/"!==m.charAt(0)||this.nomount||(m=c.join(this.root,m)),this._emitMatch(a,m)}return s()}n.shift();for(y=0;y<h;y++){m=p[y];e&&(m="/"!==e?e+"/"+m:e+m),this._process([m].concat(n),a,i,s)}s()},E.prototype._emitMatch=function(e,t){if(!this.aborted&&!g(this,t))if(this.paused)this._emitQueue.push([e,t]);else{var r=u(t)?t:this._makeAbs(t);if(this.mark&&(t=this._mark(t)),this.absolute&&(t=r),!this.matches[e][t]){if(this.nodir){var n=this.cache[r];if("DIR"===n||Array.isArray(n))return}this.matches[e][t]=!0;var a=this.statCache[r];a&&this.emit("stat",t,a),this.emit("match",t)}}},E.prototype._readdirInGlobStar=function(e,t){if(!this.aborted){if(this.follow)return this._readdir(e,!1,t);var r=this,a=h("lstat\0"+e,(function(n,a){if(n&&"ENOENT"===n.code)return t();var i=a&&a.isSymbolicLink();r.symlinks[e]=i,i||!a||a.isDirectory()?r._readdir(e,!1,t):(r.cache[e]="FILE",t())}));a&&n.lstat(e,a)}},E.prototype._readdir=function(e,t,r){if(!this.aborted&&(r=h("readdir\0"+e+"\0"+t,r))){if(t&&!y(this.symlinks,e))return this._readdirInGlobStar(e,r);if(y(this.cache,e)){var a=this.cache[e];if(!a||"FILE"===a)return r();if(Array.isArray(a))return r(null,a)}n.readdir(e,function(e,t,r){return function(n,a){n?e._readdirError(t,n,r):e._readdirEntries(t,a,r)}}(this,e,r))}},E.prototype._readdirEntries=function(e,t,r){if(!this.aborted){if(!this.mark&&!this.stat)for(var n=0;n<t.length;n++){var a=t[n];a="/"===e?e+a:e+"/"+a,this.cache[a]=!0}return this.cache[e]=t,r(null,t)}},E.prototype._readdirError=function(e,t,r){if(!this.aborted){switch(t.code){case"ENOTSUP":case"ENOTDIR":var n=this._makeAbs(e);if(this.cache[n]="FILE",n===this.cwdAbs){var a=new Error(t.code+" invalid cwd "+this.cwd);a.path=this.cwd,a.code=t.code,this.emit("error",a),this.abort()}break;case"ENOENT":case"ELOOP":case"ENAMETOOLONG":case"UNKNOWN":this.cache[this._makeAbs(e)]=!1;break;default:this.cache[this._makeAbs(e)]=!1,this.strict&&(this.emit("error",t),this.abort()),this.silent||console.error("glob error",t)}return r()}},E.prototype._processGlobStar=function(e,t,r,n,a,i,o){var s=this;this._readdir(r,i,(function(c,l){s._processGlobStar2(e,t,r,n,a,i,l,o)}))},E.prototype._processGlobStar2=function(e,t,r,n,a,i,o,s){if(!o)return s();var c=n.slice(1),l=e?[e]:[],u=l.concat(c);this._process(u,a,!1,s);var d=this.symlinks[r],f=o.length;if(d&&i)return s();for(var p=0;p<f;p++){if("."!==o[p].charAt(0)||this.dot){var y=l.concat(o[p],c);this._process(y,a,!0,s);var h=l.concat(o[p],n);this._process(h,a,!0,s)}}s()},E.prototype._processSimple=function(e,t,r){var n=this;this._stat(e,(function(a,i){n._processSimple2(e,t,a,i,r)}))},E.prototype._processSimple2=function(e,t,r,n,a){if(this.matches[t]||(this.matches[t]=Object.create(null)),!n)return a();if(e&&u(e)&&!this.nomount){var i=/[\/\\]$/.test(e);"/"===e.charAt(0)?e=c.join(this.root,e):(e=c.resolve(this.root,e),i&&(e+="/"))}"win32"===process.platform&&(e=e.replace(/\\/g,"/")),this._emitMatch(t,e),a()},E.prototype._stat=function(e,t){var r=this._makeAbs(e),a="/"===e.slice(-1);if(e.length>this.maxLength)return t();if(!this.stat&&y(this.cache,r)){var i=this.cache[r];if(Array.isArray(i)&&(i="DIR"),!a||"DIR"===i)return t(null,i);if(a&&"FILE"===i)return t()}var o=this.statCache[r];if(void 0!==o){if(!1===o)return t(null,o);var s=o.isDirectory()?"DIR":"FILE";return a&&"FILE"===s?t():t(null,s,o)}var c=this,l=h("stat\0"+r,(function(a,i){if(i&&i.isSymbolicLink())return n.stat(r,(function(n,a){n?c._stat2(e,r,null,i,t):c._stat2(e,r,n,a,t)}));c._stat2(e,r,a,i,t)}));l&&n.lstat(r,l)},E.prototype._stat2=function(e,t,r,n,a){if(r&&("ENOENT"===r.code||"ENOTDIR"===r.code))return this.statCache[t]=!1,a();var i="/"===e.slice(-1);if(this.statCache[t]=n,"/"===t.slice(-1)&&n&&!n.isDirectory())return a(null,!1,n);var o=!0;return n&&(o=n.isDirectory()?"DIR":"FILE"),this.cache[t]=this.cache[t]||o,i&&"FILE"===o?a():a(null,o,n)}},function(e,t,r){e.exports=u,u.realpath=u,u.sync=d,u.realpathSync=d,u.monkeypatch=function(){n.realpath=u,n.realpathSync=d},u.unmonkeypatch=function(){n.realpath=a,n.realpathSync=i};var n=r(23),a=n.realpath,i=n.realpathSync,o=process.version,s=/^v[0-5]\./.test(o),c=r(85);function l(e){return e&&"realpath"===e.syscall&&("ELOOP"===e.code||"ENOMEM"===e.code||"ENAMETOOLONG"===e.code)}function u(e,t,r){if(s)return a(e,t,r);"function"==typeof t&&(r=t,t=null),a(e,t,(function(n,a){l(n)?c.realpath(e,t,r):r(n,a)}))}function d(e,t){if(s)return i(e,t);try{return i(e,t)}catch(r){if(l(r))return c.realpathSync(e,t);throw r}}},function(e,t){e.exports=require("assert")},function(e,t,r){function n(e,t){return Object.prototype.hasOwnProperty.call(e,t)}t.alphasort=l,t.alphasorti=c,t.setopts=function(e,t,r){r||(r={});if(r.matchBase&&-1===t.indexOf("/")){if(r.noglobstar)throw new Error("base matching requires globstar");t="**/"+t}e.silent=!!r.silent,e.pattern=t,e.strict=!1!==r.strict,e.realpath=!!r.realpath,e.realpathCache=r.realpathCache||Object.create(null),e.follow=!!r.follow,e.dot=!!r.dot,e.mark=!!r.mark,e.nodir=!!r.nodir,e.nodir&&(e.mark=!0);e.sync=!!r.sync,e.nounique=!!r.nounique,e.nonull=!!r.nonull,e.nosort=!!r.nosort,e.nocase=!!r.nocase,e.stat=!!r.stat,e.noprocess=!!r.noprocess,e.absolute=!!r.absolute,e.maxLength=r.maxLength||1/0,e.cache=r.cache||Object.create(null),e.statCache=r.statCache||Object.create(null),e.symlinks=r.symlinks||Object.create(null),function(e,t){e.ignore=t.ignore||[],Array.isArray(e.ignore)||(e.ignore=[e.ignore]);e.ignore.length&&(e.ignore=e.ignore.map(u))}(e,r),e.changedCwd=!1;var i=process.cwd();n(r,"cwd")?(e.cwd=a.resolve(r.cwd),e.changedCwd=e.cwd!==i):e.cwd=i;e.root=r.root||a.resolve(e.cwd,"/"),e.root=a.resolve(e.root),"win32"===process.platform&&(e.root=e.root.replace(/\\/g,"/"));e.cwdAbs=o(e.cwd)?e.cwd:d(e,e.cwd),"win32"===process.platform&&(e.cwdAbs=e.cwdAbs.replace(/\\/g,"/"));e.nomount=!!r.nomount,r.nonegate=!0,r.nocomment=!0,e.minimatch=new s(t,r),e.options=e.minimatch.options},t.ownProp=n,t.makeAbs=d,t.finish=function(e){for(var t=e.nounique,r=t?[]:Object.create(null),n=0,a=e.matches.length;n<a;n++){var i=e.matches[n];if(i&&0!==Object.keys(i).length){var o=Object.keys(i);t?r.push.apply(r,o):o.forEach((function(e){r[e]=!0}))}else if(e.nonull){var s=e.minimatch.globSet[n];t?r.push(s):r[s]=!0}}t||(r=Object.keys(r));e.nosort||(r=r.sort(e.nocase?c:l));if(e.mark){for(n=0;n<r.length;n++)r[n]=e._mark(r[n]);e.nodir&&(r=r.filter((function(t){var r=!/\/$/.test(t),n=e.cache[t]||e.cache[d(e,t)];return r&&n&&(r="DIR"!==n&&!Array.isArray(n)),r})))}e.ignore.length&&(r=r.filter((function(t){return!f(e,t)})));e.found=r},t.mark=function(e,t){var r=d(e,t),n=e.cache[r],a=t;if(n){var i="DIR"===n||Array.isArray(n),o="/"===t.slice(-1);if(i&&!o?a+="/":!i&&o&&(a=a.slice(0,-1)),a!==t){var s=d(e,a);e.statCache[s]=e.statCache[r],e.cache[s]=e.cache[r]}}return a},t.isIgnored=f,t.childrenIgnored=function(e,t){return!!e.ignore.length&&e.ignore.some((function(e){return!(!e.gmatcher||!e.gmatcher.match(t))}))};var a=r(10),i=r(32),o=r(33),s=i.Minimatch;function c(e,t){return e.toLowerCase().localeCompare(t.toLowerCase())}function l(e,t){return e.localeCompare(t)}function u(e){var t=null;if("/**"===e.slice(-3)){var r=e.replace(/(\/\*\*)+$/,"");t=new s(r,{dot:!0})}return{matcher:new s(e,{dot:!0}),gmatcher:t}}function d(e,t){var r=t;return r="/"===t.charAt(0)?a.join(e.root,t):o(t)||""===t?t:e.changedCwd?a.resolve(e.cwd,t):a.resolve(t),"win32"===process.platform&&(r=r.replace(/\\/g,"/")),r}function f(e,t){return!!e.ignore.length&&e.ignore.some((function(e){return e.matcher.match(t)||!(!e.gmatcher||!e.gmatcher.match(t))}))}},function(e,t){e.exports=function e(t,r){if(t&&r)return e(t)(r);if("function"!=typeof t)throw new TypeError("need wrapper function");return Object.keys(t).forEach((function(e){n[e]=t[e]})),n;function n(){for(var e=new Array(arguments.length),r=0;r<e.length;r++)e[r]=arguments[r];var n=t.apply(this,e),a=e[e.length-1];return"function"==typeof n&&n!==a&&Object.keys(a).forEach((function(e){n[e]=a[e]})),n}}},function(e,t,r){var n=r(50);function a(e){var t=function(){return t.called?t.value:(t.called=!0,t.value=e.apply(this,arguments))};return t.called=!1,t}function i(e){var t=function(){if(t.called)throw new Error(t.onceError);return t.called=!0,t.value=e.apply(this,arguments)},r=e.name||"Function wrapped with `once`";return t.onceError=r+" shouldn't be called more than once",t.called=!1,t}e.exports=n(a),e.exports.strict=n(i),a.proto=a((function(){Object.defineProperty(Function.prototype,"once",{value:function(){return a(this)},configurable:!0}),Object.defineProperty(Function.prototype,"onceStrict",{value:function(){return i(this)},configurable:!0})}))},function(e,t,r){var n={};e.exports=n,n.themes={};var a=r(15),i=n.styles=r(108),o=Object.defineProperties,s=new RegExp(/[\r\n]+/g);n.supportsColor=r(109).supportsColor,void 0===n.enabled&&(n.enabled=!1!==n.supportsColor()),n.enable=function(){n.enabled=!0},n.disable=function(){n.enabled=!1},n.stripColors=n.strip=function(e){return(""+e).replace(/\x1B\[\d+m/g,"")};n.stylize=function(e,t){if(!n.enabled)return e+"";var r=i[t];return!r&&t in n?n[t](e):r.open+e+r.close};var c=/[|\\{}()[\]^$+*?.]/g;function l(e){var t=function e(){return p.apply(e,arguments)};return t._styles=e,t.__proto__=f,t}var u,d=(u={},i.grey=i.gray,Object.keys(i).forEach((function(e){i[e].closeRe=new RegExp(function(e){if("string"!=typeof e)throw new TypeError("Expected a string");return e.replace(c,"\\$&")}(i[e].close),"g"),u[e]={get:function(){return l(this._styles.concat(e))}}})),u),f=o((function(){}),d);function p(){var e=Array.prototype.slice.call(arguments),t=e.map((function(e){return null!=e&&e.constructor===String?e:a.inspect(e)})).join(" ");if(!n.enabled||!t)return t;for(var r=-1!=t.indexOf("\n"),o=this._styles,c=o.length;c--;){var l=i[o[c]];t=l.open+t.replace(l.closeRe,l.open)+l.close,r&&(t=t.replace(s,(function(e){return l.close+e+l.open})))}return t}n.setTheme=function(e){if("string"!=typeof e)for(var t in e)!function(t){n[t]=function(r){if("object"==typeof e[t]){var a=r;for(var i in e[t])a=n[e[t][i]](a);return a}return n[e[t]](r)}}(t);else console.log("colors.setTheme now only accepts an object, not a string.  If you are trying to set a theme from a file, it is now your (the caller's) responsibility to require the file.  The old syntax looked like colors.setTheme(__dirname + '/../themes/generic-logging.js'); The new syntax looks like colors.setTheme(require(__dirname + '/../themes/generic-logging.js'));")};var y=function(e,t){var r=t.split("");return(r=r.map(e)).join("")};for(var h in n.trap=r(112),n.zalgo=r(113),n.maps={},n.maps.america=r(114)(n),n.maps.zebra=r(115)(n),n.maps.rainbow=r(116)(n),n.maps.random=r(117)(n),n.maps)!function(e){n[e]=function(t){return y(n.maps[e],t)}}(h);o(n,function(){var e={};return Object.keys(d).forEach((function(t){e[t]={get:function(){return l([t])}}})),e}())},function(e,t,r){var n=r(54).default;e.exports=n},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=g(r(24)),a=g(r(0)),i=g(r(55)),o=r(4),s=g(r(16)),c=g(r(27)),l=g(r(31)),u=g(r(5)),d=g(r(8)),f=g(r(9)),p=g(r(28)),y=g(r(22)),h=g(r(30)),m=r(3);function g(e){return e&&e.__esModule?e:{default:e}}(0,a.default)("debugger");const b={forTx:(_=(0,n.default)((function*(e,t={}){let{contracts:r,files:n,provider:a,compilations:o,lightMode:s}=t;o||(o=m.Compilations.Utils.shimArtifacts(r,n));let c=new i.default(o,a,{lightMode:s},e);return yield c.ready(),c})),function(e){return _.apply(this,arguments)}),forProject:(v=(0,n.default)((function*(e={}){let{contracts:t,files:r,provider:n,compilations:a,lightMode:o}=e;a||(a=m.Compilations.Utils.shimArtifacts(t,r));let s=new i.default(a,n,{lightMode:o});return yield s.ready(),s})),function(){return v.apply(this,arguments)}),get selectors(){return(0,o.createNestedSelector)({ast:l.default,data:s.default,txlog:c.default,trace:u.default,evm:d.default,solidity:f.default,stacktrace:y.default,session:p.default,controller:h.default})}};var v,_;t.default=b},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=x(r(11)),a=x(r(12)),i=x(r(2)),o=x(r(24)),s=x(r(56)),c=x(r(0)),l=N(r(57)),u=N(r(3)),d=r(1),f=x(r(59)),p=N(r(25)),y=N(r(18)),h=x(r(16)),m=x(r(27)),g=x(r(22)),b=x(r(28)),v=N(r(17)),_=N(r(39)),E=N(r(70)),T=x(r(30)),A=r(4),S=x(r(31)),R=x(r(5)),C=x(r(8)),O=x(r(9)),L=x(r(72)),I=r(81);function N(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t}function x(e){return e&&e.__esModule?e:{default:e}}const w=(0,c.default)("debugger:session");class D{constructor(e,t,r,n){let{store:a,sagaMiddleware:i}=(0,f.default)(L.default,E.default,[r]);this._store=a,this._sagaMiddleware=i;let{contexts:o,sources:c}=D.normalize(e);this._store.dispatch(y.recordContracts(o,c)),this._ready=new s.default((e,t)=>{const r=this._store.subscribe(()=>{this.view(b.default.status.ready)?(w("ready!"),r(),e()):this.view(b.default.status.errored)&&(w("error!"),r(),t(this.view(b.default.status.error)))})}),this._store.dispatch(y.start(t,n))}ready(){var e=this;return(0,o.default)((function*(){yield e._ready}))()}readyAgainAfterLoading(e){var t=this;return(0,o.default)((function*(){return new s.default((function(r,n){let a=!1;w("reready listener set up");const i=t._store.subscribe((function(){w("reready?"),a?t.view(b.default.status.ready)?(w("reready!"),i(),r(!0)):t.view(b.default.status.errored)&&(i(),w("error!"),n(t.view(b.default.status.error))):t.view(b.default.status.waiting)&&(w("started waiting"),a=!0)}));t.dispatch(e)}))}))()}static normalize(e){let t=[],r={user:{},internal:{}};const n=(e,t,r)=>(0,d.stableKeccak256)({compilationId:e,contextHash:t,index:r});for(let a of e){if(a.unreliableSourceOrder)throw new Error(`Error: Compilation ${a.id} has unreliable source order.`);let e=a.compiler;r.user[a.id]=[];for(let t in a.sources){t=Number(t);let o=a.sources[t];if(!o)continue;let s=o.ast;s&&!s.nodeType&&(s=void 0),r.user[a.id][t]=(0,i.default)({},o,{ast:s,compiler:o.compiler||e,compilationId:a.id,index:t,id:n(a.id,null,t),internal:!1})}for(let e of a.contracts){let o,{contractName:s,bytecode:c,sourceMap:f,deployedBytecode:p,deployedSourceMap:y,immutableReferences:h,abi:m,compiler:g,primarySourceId:b,generatedSources:v,deployedGeneratedSources:_}=e;w("contractName: %s",s),"object"==typeof c&&(c=I.Shims.NewToLegacy.forBytecode(c)),"object"==typeof p&&(p=I.Shims.NewToLegacy.forBytecode(p)),void 0!==b&&(o=a.sources.findIndex(e=>e&&e.id===b));const E=u.Compilations.Utils.getContractNode(e,a),T=E?E.id:void 0,A=E?E.contractKind:void 0,S=E?E.linearizedBaseContracts:void 0;if(m=l.normalize(m),w("contractName %s",s),w("sourceMap %o",f),w("compiler %o",g),w("abi %o",m),f=u.Compilations.Utils.simpleShimSourceMap(f),y=u.Compilations.Utils.simpleShimSourceMap(y),c&&"0x"!=c){const e=(0,d.keccak256)({type:"string",value:c});if(t.push({context:e,contractName:s,binary:c,sourceMap:f,primarySource:o,abi:m,compiler:g,compilationId:a.id,contractId:T,contractKind:A,linearizedBaseContracts:S,isConstructor:!0}),v){r.internal[e]=[];for(let t in v){t=Number(t);const o=v[t];r.internal[e][t]=(0,i.default)({},o,{compiler:o.compiler||g,compilationId:a.id,index:t,id:n(a.id,e,t),internal:!0,internalFor:e})}}}if(p&&"0x"!=p){const e=(0,d.keccak256)({type:"string",value:p});if(t.push({context:e,contractName:s,binary:p,sourceMap:y,primarySource:o,immutableReferences:h,abi:m,compiler:g,compilationId:a.id,contractId:T,contractKind:A,linearizedBaseContracts:S,isConstructor:!1}),_){r.internal[e]=[];for(let t in _){t=Number(t);const o=_[t];r.internal[e][t]=(0,i.default)({},o,{compiler:o.compiler||g,compilationId:a.id,index:t,id:n(a.id,e,t),internal:!0,internalFor:e})}}}}}return t=(0,a.default)({},...t.map(e=>({[e.context]:(0,i.default)({},e)}))),t=u.Contexts.Utils.normalizeContexts(t),{contexts:t,sources:r}}get state(){return this._store.getState()}view(e){return e(this.state)}dispatch(e){var t=this;return(0,o.default)((function*(){return t._store.dispatch(e),!0}))()}_runSaga(e,...t){var r=this;return(0,o.default)((function*(){return yield r._sagaMiddleware.run(e,...t).toPromise()}))()}interrupt(){var e=this;return(0,o.default)((function*(){yield e.dispatch(y.interrupt()),yield e.dispatch(p.interrupt())}))()}doneStepping(e){var t=this;return(0,o.default)((function*(){return new s.default((function(r){let n=!1;const a=t._store.subscribe((function(){const e=t.view(T.default.isStepping);!e||n?!e&&n&&(a(),r(!0)):n=!0}));t.dispatch(e)}))}))()}load(e){var t=this;return(0,o.default)((function*(){return!t.view(b.default.status.loaded)&&(yield t.readyAgainAfterLoading(y.loadTransaction(e)))}))()}unload(){var e=this;return(0,o.default)((function*(){return!!e.view(b.default.status.loaded)&&(w("unloading"),yield e._runSaga(E.unload),!0)}))()}advance(e){var t=this;return(0,o.default)((function*(){return yield t.doneStepping(p.advance(e))}))()}stepNext(){var e=this;return(0,o.default)((function*(){return yield e.doneStepping(p.stepNext())}))()}stepOver(){var e=this;return(0,o.default)((function*(){return yield e.doneStepping(p.stepOver())}))()}stepInto(){var e=this;return(0,o.default)((function*(){return yield e.doneStepping(p.stepInto())}))()}stepOut(){var e=this;return(0,o.default)((function*(){return yield e.doneStepping(p.stepOut())}))()}reset(){var e=this;return(0,o.default)((function*(){if(e.view(b.default.status.loaded))return yield e._runSaga(_.reset)}))()}continueUntilBreakpoint(e){var t=this;return(0,o.default)((function*(){return yield t.doneStepping(p.continueUntilBreakpoint(e))}))()}addBreakpoint(e){var t=this;return(0,o.default)((function*(){return yield t.dispatch(p.addBreakpoint(e))}))()}removeBreakpoint(e){var t=this;return(0,o.default)((function*(){return yield t.dispatch(p.removeBreakpoint(e))}))()}removeAllBreakpoints(){var e=this;return(0,o.default)((function*(){return yield e.dispatch(p.removeAllBreakpoints())}))()}setInternalStepping(e){var t=this;return(0,o.default)((function*(){return yield t.dispatch(p.setInternalStepping(e))}))()}decodeReady(){return(0,o.default)((function*(){return!0}))()}variable(e){var t=this;return(0,o.default)((function*(){const r=t.view(h.default.current.identifiers.definitions),n=t.view(h.default.current.identifiers.refs),a=t.view(h.default.current.compilationId);return w("name: %s",e),w("refs: %O",n),w("definitions: %o",r),yield t._runSaga(v.decode,r[e],n[e],a)}))()}variables(){var e=this;return(0,o.default)((function*(){if(!e.view(b.default.status.loaded))return{};let t=e.view(h.default.current.identifiers.definitions),r=e.view(h.default.current.identifiers.refs),a=e.view(h.default.current.compilationId),i={};for(let[o,s]of(0,n.default)(r))o in t&&(i[o]=yield e._runSaga(v.decode,t[o],s,a));return i}))()}returnValue(){var e=this;return(0,o.default)((function*(){return e.view(b.default.status.loaded)&&e.view(C.default.current.step.isHalting)?yield e._runSaga(v.decodeReturnValue):null}))()}callstack(){return this.view(b.default.status.loaded)?this.view(g.default.current.report):null}stacktrace(){return this.view(b.default.status.loaded)?this.view(g.default.current.finalReport):null}connect(){return this}addExternalCompilations(e){var t=this;return(0,o.default)((function*(){let{contexts:r,sources:n}=D.normalize(e);return yield t.dispatch(y.addCompilations(n,r))}))()}startFullMode(){var e=this;return(0,o.default)((function*(){return yield e.dispatch(y.startFullMode())}))()}get selectors(){return(0,A.createNestedSelector)({ast:S.default,data:h.default,txlog:m.default,trace:R.default,evm:C.default,solidity:O.default,stacktrace:g.default,session:b.default,controller:T.default})}}t.default=D},function(e,t){e.exports=require("babel-runtime/core-js/promise")},function(e,t){e.exports=require("@truffle/abi-utils")},function(e,t){e.exports=require("json-stable-stringify")},function(e,t,r){"use strict";e.exports=r(60)},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n,a=r(61),i=(n=a)&&n.__esModule?n:{default:n};t.default=i.default},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,r,n,o){const s=(0,i.default)();o||(o=a.compose);let c=(0,a.createStore)(e,n,o((0,a.applyMiddleware)(s)));return s.run(t,...r),{store:c,sagaMiddleware:s}};var n=o(r(0)),a=r(7),i=o(r(62));function o(e){return e&&e.__esModule?e:{default:e}}(0,n.default)("debugger:store:common")},function(e,t){e.exports=require("redux-saga")},function(e,t){e.exports=require("lodash.merge")},function(e,t){e.exports=require("@truffle/source-map-utils")},function(e,t){e.exports=require("lodash.zipwith")},function(e,t){e.exports=require("babel-runtime/core-js/set")},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.init=function(e){return{type:n,provider:e}},t.inspect=function(e){return{type:a,txHash:e}},t.fetchBinary=function(e,t){return{type:i,address:e,block:t}},t.receiveBinary=function(e,t){return{type:o,address:e,binary:t}},t.receiveTrace=function(e){return{type:s,trace:e}},t.receiveCall=function({address:e,binary:t,data:r,storageAddress:n,status:a,sender:i,value:o,gasprice:s,block:l}){return{type:c,address:e,binary:t,data:r,storageAddress:n,status:a,sender:i,value:o,gasprice:s,block:l}},t.error=function(e){return{type:l,error:e}};const n=t.INIT_WEB3="INIT_WEB3";const a=t.INSPECT="INSPECT_TRANSACTION";const i=t.FETCH_BINARY="FETCH_BINARY";const o=t.RECEIVE_BINARY="RECEIVE_BINARY";const s=t.RECEIVE_TRACE="RECEIVE_TRACE";const c=t.RECEIVE_CALL="RECEIVE_CALL";const l=t.ERROR_WEB3="ERROR_WEB3"},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=s(r(24)),a=s(r(0)),i=s(r(38)),o=r(15);function s(e){return e&&e.__esModule?e:{default:e}}const c=(0,a.default)("debugger:web3:adapter");t.default=class{constructor(e){this.web3=new i.default(e)}getTrace(e){var t=this;return(0,n.default)((function*(){let r=yield(0,o.promisify)(t.web3.currentProvider.send)({jsonrpc:"2.0",method:"debug_traceTransaction",params:[e,{}],id:(new Date).getTime()});if(r.result)return r.result.structLogs;throw new Error(r.error.message)}))()}getTransaction(e){var t=this;return(0,n.default)((function*(){return yield t.web3.eth.getTransaction(e)}))()}getReceipt(e){var t=this;return(0,n.default)((function*(){return yield t.web3.eth.getTransactionReceipt(e)}))()}getBlock(e){var t=this;return(0,n.default)((function*(){return yield t.web3.eth.getBlock(e)}))()}getChainId(){var e=this;return(0,n.default)((function*(){return yield e.web3.eth.getChainId()}))()}getDeployedCode(e,t){var r=this;return(0,n.default)((function*(){c("getting deployed code for %s",e);let n=yield r.web3.eth.getCode(e,t);return"0x0"===n?"0x":n}))()}}},function(e,t){e.exports=require("lodash.sum")},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=_(r(19)),a=_(r(26));t.saga=S,t.processTransaction=R,t.unload=function*(){E("unloading"),yield*y.reset(),yield*u.unload(),yield*f.unload(),yield*p.unload(),yield*d.unload(),yield*h.unload(),yield(0,o.put)(g.unloadTransaction())};var i=_(r(0)),o=r(6),s=r(1),c=v(r(71)),l=v(r(39)),u=v(r(42)),d=v(r(44)),f=v(r(29)),p=v(r(14)),y=v(r(17)),h=v(r(40)),m=v(r(37)),g=v(r(18)),b=_(r(28));function v(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t}function _(e){return e&&e.__esModule?e:{default:e}}const E=(0,i.default)("debugger:session:sagas"),T={[g.LOAD_TRANSACTION]:function*({txHash:e}){yield*R(e)},[g.ADD_COMPILATIONS]:function*({sources:e,contexts:t}){E("recording contract binaries"),yield*C(t),E("recording contract sources"),yield*O(e),E("refreshing instances"),yield*f.refreshInstances()},[g.START_FULL_MODE]:function*(){if(E("session: %O",b.default),!(yield(0,o.select)(b.default.status.lightMode)))return;E("turning on data & txlog listeners");const e=[y.saga,h.saga];for(let t of e)yield(0,o.fork)(t);E("visiting ASTs"),yield*c.visitAll(),E("saving allocation table"),yield*y.recordAllocations(),yield*p.addSubmoduleToCount(e.length),yield*h.begin(),yield(0,o.put)(g.setFullMode())}};function*A(){for(;;){let e=yield(0,o.take)((0,a.default)(T)),t=T[e.type];yield(0,o.put)(g.wait()),yield(0,o.race)({exec:(0,o.call)(t,e),interrupt:(0,o.take)(g.INTERRUPT)}),yield(0,o.put)(g.ready())}}function*S(e){E("starting listeners"),yield*function*(e){yield(0,o.fork)(A);let t=[f,u,d];e.lightMode||(t.push(y),t.push(h));let r=[p,l,m];const n=t.length,a=t.concat(r);return yield*p.setSubmoduleCount(n),yield(0,o.all)(a.map(e=>(0,o.fork)(e.saga)))}(e),E("waiting for contract information");let{contexts:t,sources:r}=yield(0,o.take)(g.RECORD_CONTRACTS);E("recording contract binaries"),yield*C(t),E("recording contract sources"),yield*O(r),E("waiting for start");let{txHash:n,provider:a}=yield(0,o.take)(g.START);E("starting"),e.lightMode?(E("setting light mode"),yield(0,o.put)(g.setLightMode())):(E("visiting ASTs"),yield*c.visitAll(),E("saving allocation table"),yield*y.recordAllocations()),E("initializing adapter"),yield*m.init(a),void 0!==n&&(yield*R(n)),E("readying"),yield*function*(){yield(0,o.put)(g.ready())}()}function*R(e){E("fetching transaction info");let t=yield*function*(e){let t=yield*m.inspectTransaction(e);if(E("result %o",t),t.error)return t.error;E("processing trace for addresses");let{calls:r,creations:n,selfdestructs:i}=yield*p.processTrace(t.trace);t.address&&!r.includes(t.address)&&r.push(t.address);t.binary&&t.status&&!(t.storageAddress in n)&&(n[t.storageAddress]=t.binary);let s=t.block.number.toString(),c=[...r,...i,...(0,a.default)(n)],l=r.length;E("obtaining binaries");let y=yield*m.obtainBinaries(c,s);E("recording instances"),yield(0,o.all)(c.map((e,t)=>(0,o.call)(L,e,y[t],t>=l,n[e]))),E("sending initial call"),yield*f.begin(t),yield*u.begin(),yield*d.begin(),(yield(0,o.select)(b.default.status.lightMode))||(yield*h.begin())}(e);t&&(E("error %o",t),yield*function*(e){yield(0,o.put)(g.error(e))}(t))}function*C(e){for(let t of(0,n.default)(e))yield*f.addContext(t)}function*O(e){yield*u.addSources(e)}function*L(e,t,r,n){yield*f.addAffectedInstance(e,t,n),r||(yield*f.addInstance(e,t))}t.default=(0,s.prefixName)("session",S)},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=l(r(11));t.visitAll=function*(){const e=yield(0,i.select)(s.default.views.sources);yield(0,i.all)(e.filter(({ast:e})=>e).map(({ast:e,id:t,index:r})=>(0,i.call)(d,t,r,e))),u("done visiting")};var a=l(r(0)),i=r(6),o=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t}(r(17)),s=l(r(31)),c=l(r(20));function l(e){return e&&e.__esModule?e:{default:e}}const u=(0,a.default)("debugger:ast:sagas");function*d(e,t,r,a="",i=null){if(u("walking %s %o %o",e,a,r),yield*function*(e,t,r,n,a){if(u("entering %s %s",e,n),!(r instanceof Object))return;void 0!==r.id&&(u("%s recording scope %s",n,r.id),yield*o.scope(r.id,n,a,t,e));switch(r.nodeType){case"VariableDeclaration":u("%s recording variable %o",n,r),yield*o.declare(r,e);break;case"ContractDefinition":case"StructDefinition":case"EnumDefinition":u("%s recording type %o",n,r),yield*o.defineType(r,e);break;case"EventDefinition":case"ErrorDefinition":u("%s recording type %o",n,r),yield*o.defineTaggedOutput(r,e)}}(e,t,r,a,i),Array.isArray(r))for(let[n,o]of r.entries())yield*d(e,t,o,`${a}/${n}`,i);else if(r&&r.nodeType&&r.nodeType.startsWith("Yul"))yield*function*(e,t,r,a,i){yield*function*e(t,r,a,i,s,l,d){if(yield*function*(e,t,r,n,a,i,s){if(u("entering %s %s",e,n),!r)return;void 0!==r.src&&(u("scoping!"),yield*o.yulScope(n,t,e,s));if("YulTypedName"===r.nodeType){let s=function e(t,r,n,a){u("pointer: %s",r),u("basePointer: %s",a);let i=r.slice(a.length);u("relativePointer: %s",i);let o=i.replace(/\/[^/]*$/,""),s=a+o;u("parentPointer: %s",s);let l=c.default.get(n,o);return"YulBlock"===t.nodeType?"YulForLoop"===l.nodeType&&r===s+"/pre"?s:r:"YulFunctionDefinition"===t.nodeType?r:e(l,s,n,a)}(r,n,a,i);yield*o.yulDeclare(r,n,s,t,e)}}(t,r,a,i,s,l,d),Array.isArray(a))for(let[n,o]of a.entries())yield*e(t,r,o,`${i}/${n}`,s,l);else if(a instanceof Object)for(let[o,c]of(0,n.default)(a))yield*e(t,r,c,`${i}/${o}`,s,l);yield*function*(e,t,r,n,a,i,o){u("exiting %s %s",e,n)}(t,0,0,i)}(e,t,r,a,r,a,i)}(e,t,r,a,i);else if(r instanceof Object)for(let[i,o]of(0,n.default)(r))yield*d(e,t,o,`${a}/${i}`,r.id);yield*function*(e,t,r,n){u("exiting %s %s",e,n)}(e,0,0,a)}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=p(r(0)),a=r(7),i=p(r(73)),o=p(r(74)),s=p(r(75)),c=p(r(77)),l=p(r(78)),u=p(r(79)),d=p(r(80)),f=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t}(r(18));function p(e){return e&&e.__esModule?e:{default:e}}const y=(0,n.default)("debugger:session:reducers");const h=(0,a.combineReducers)({ready:function(e=!1,t){switch(t.type){case f.READY:return y("readying"),!0;case f.WAIT:return!1;default:return e}},lastLoadingError:function(e=null,t){switch(t.type){case f.ERROR:return y("error: %o",t.error),t.error;case f.WAIT:return null;default:return e}},transaction:function(e={},t){switch(t.type){case f.SAVE_TRANSACTION:return t.transaction;case f.UNLOAD_TRANSACTION:return{};default:return e}},receipt:function(e={},t){switch(t.type){case f.SAVE_RECEIPT:return t.receipt;case f.UNLOAD_TRANSACTION:return{};default:return e}},block:function(e={},t){switch(t.type){case f.SAVE_BLOCK:return t.block;case f.UNLOAD_TRANSACTION:return{};default:return e}},lightMode:function(e=!1,t){switch(t.type){case f.SET_LIGHT_MODE:return!0;case f.SET_FULL_MODE:return!1;default:return e}}}),m=(0,a.combineReducers)({session:h,data:i.default,txlog:d.default,evm:o.default,solidity:s.default,stacktrace:u.default,trace:c.default,controller:l.default});t.default=m},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=d(r(12)),a=d(r(2)),i=d(r(0)),o=r(7),s=u(r(35)),c=u(r(3)),l=r(1);function u(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t}function d(e){return e&&e.__esModule?e:{default:e}}const f=(0,i.default)("debugger:data:reducers"),p={bySourceId:{}};const y={storage:{},memory:{},abi:{},calldata:{},returndata:{},state:{}};const h=(0,o.combineReducers)({scopes:function(e=p,t){switch(t.type){case s.SCOPE:{const{sourceId:r,id:n,sourceIndex:i,parentId:o,pointer:s}=t,c=void 0!==n?n:(0,l.makePath)(i,s);return{bySourceId:(0,a.default)({},e.bySourceId,{[r]:{byAstRef:(0,a.default)({},(e.bySourceId[r]||{}).byAstRef,{[c]:(0,a.default)({},(e.bySourceId[r]||{byAstRef:{}}).byAstRef[c],{id:n,parentId:o,sourceIndex:i,pointer:s,sourceId:r})})}})}}case s.DECLARE:{let{sourceId:r,name:n,astRef:i,scopeAstRef:o}=t,s=e.bySourceId[r].byAstRef[o],c=s.variables||[];return{bySourceId:(0,a.default)({},e.bySourceId,{[r]:{byAstRef:(0,a.default)({},e.bySourceId[r].byAstRef,{[o]:(0,a.default)({},s,{variables:[...c,{name:n,astRef:i,sourceId:r}]})})}})}}default:return e}},userDefinedTypes:function(e=[],t){switch(t.type){case s.DEFINE_TYPE:return f("action: %O",t),[...e,{id:t.node.id,sourceId:t.sourceId}];default:return e}},taggedOutputs:function(e=[],t){switch(t.type){case s.DEFINE_TAGGED_OUTPUT:return[...e,{id:t.node.id,sourceId:t.sourceId}];default:return e}},allocations:function(e=y,t){return t.type===s.ALLOCATE?(f("action: %O",t),{storage:t.storage,memory:t.memory,abi:t.abi,calldata:t.calldata,returndata:t.returndata,state:t.state}):e}}),m=[[{builtin:"msg"},{location:"special",special:"msg"}],[{builtin:"tx"},{location:"special",special:"tx"}],[{builtin:"block"},{location:"special",special:"block"}],[{builtin:"this"},{location:"special",special:"this"}],[{builtin:"now"},{location:"special",special:"timestamp"}]].map(([e,t])=>(0,l.makeAssignment)(e,t)),g={byId:(0,n.default)({},...m.map(e=>({[e.id]:e})))};const b={byAddress:{}};const v=(0,o.combineReducers)({assignments:function(e=g,t){switch(t.type){case s.ASSIGN:case s.MAP_PATH_AND_ASSIGN:return f("action.type %O",t.type),f("action.assignments %O",t.assignments),{byId:(0,a.default)({},e.byId,t.assignments)};case s.RESET:return g;default:return e}},mappedPaths:function(e=b,t){switch(t.type){case s.MAP_PATH_AND_ASSIGN:let{address:r,slot:n,typeIdentifier:i,parentType:o}=t;f("typeIdentifier %s",i),i=c.Ast.Utils.regularizeTypeIdentifier(i),o=c.Ast.Utils.regularizeTypeIdentifier(o),f("slot %o",n);let l=c.Conversion.toHexString(c.Storage.Utils.slotAddress(n),c.Evm.Utils.WORD_SIZE),u=n.path?c.Conversion.toHexString(c.Storage.Utils.slotAddress(n.path),c.Evm.Utils.WORD_SIZE):void 0,d=(0,a.default)({},e,{byAddress:(0,a.default)({},e.byAddress,{[r]:{byType:(0,a.default)({},(e.byAddress[r]||{byType:{}}).byType)}})});if(d.byAddress[r].byType=(0,a.default)({},d.byAddress[r].byType,{[i]:{bySlotAddress:(0,a.default)({},(d.byAddress[r].byType[i]||{bySlotAddress:{}}).bySlotAddress)}}),void 0===d.byAddress[r].byType[i].bySlotAddress[l]){let e;f("parentAddress %o",u),e=void 0!==u&&d.byAddress[r].byType[o]&&d.byAddress[r].byType[o].bySlotAddress[u]?(0,a.default)({},n,{path:d.byAddress[r].byType[o].bySlotAddress[u]}):n,d.byAddress[r].byType[i].bySlotAddress[l]=e}return d;case s.RESET:return b;default:return e}}}),_=(0,o.combineReducers)({info:h,proc:v});t.default=_},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=u(r(2)),a=u(r(0)),i=r(7),o=l(r(36)),s=l(r(3)),c=u(r(21));function l(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t}function u(e){return e&&e.__esModule?e:{default:e}}const d=(0,a.default)("debugger:evm:reducers"),f={byContext:{}};const p=(0,i.combineReducers)({contexts:function(e=f,t){switch(t.type){case o.ADD_CONTEXT:const{context:r,contractName:a,binary:i,sourceMap:c,primarySource:l,immutableReferences:u,compiler:f,compilationId:p,abi:y,contractId:h,contractKind:m,isConstructor:g,linearizedBaseContracts:b}=t;return d("action %O",t),(0,n.default)({},e,{byContext:(0,n.default)({},e.byContext,{[r]:{context:r,contractName:a,context:r,binary:i,sourceMap:c,primarySource:l,immutableReferences:u,compiler:f,compilationId:p,abi:y,contractId:h,contractKind:m,isConstructor:g,linearizedBaseContracts:b,payable:s.AbiData.Utils.abiHasPayableFallback(y)}})});default:return e}}}),y={gasprice:new c.default(0),origin:s.Evm.Utils.ZERO_ADDRESS};const h={coinbase:s.Evm.Utils.ZERO_ADDRESS,difficulty:new c.default(0),gaslimit:new c.default(0),number:new c.default(0),timestamp:new c.default(0),chainid:new c.default(0)};const m=(0,i.combineReducers)({tx:function(e=y,t){switch(t.type){case o.SAVE_GLOBALS:let{gasprice:r,origin:n}=t;return{gasprice:r,origin:n};case o.UNLOAD_TRANSACTION:return y;default:return e}},block:function(e=h,t){switch(t.type){case o.SAVE_GLOBALS:return t.block;case o.UNLOAD_TRANSACTION:return h;default:return e}}});const g={byAddress:{}};const b=(0,i.combineReducers)({globals:m,status:function(e=null,t){switch(t.type){case o.SAVE_STATUS:return t.status;case o.UNLOAD_TRANSACTION:return null;default:return e}},initialCall:function(e=null,t){switch(t.type){case o.CALL:case o.CREATE:return null!==e?e:t;case o.UNLOAD_TRANSACTION:return null;default:return e}},affectedInstances:function(e=g,t){switch(t.type){case o.ADD_AFFECTED_INSTANCE:const{address:r,binary:a,context:i,creationBinary:s,creationContext:c}=t;return{byAddress:(0,n.default)({},e.byAddress,{[r]:{address:r,binary:a,context:i,creationBinary:s,creationContext:c}})};case o.UNLOAD_TRANSACTION:return g;default:return e}}});const v=[{accounts:{}}];const _=(0,i.combineReducers)({callstack:function(e=[],t){switch(t.type){case o.CALL:{const{address:r,data:n,storageAddress:a,sender:i,value:o}=t;return e.concat([{address:r,data:n,storageAddress:a,sender:i,value:o}])}case o.CREATE:{const{binary:r,storageAddress:n,sender:a,value:i}=t;return e.concat([{binary:r,data:"0x",storageAddress:n,sender:a,value:i}])}case o.RETURN_CALL:case o.RETURN_CREATE:case o.FAIL:return e.length>1?e.slice(0,-1):e;case o.RESET:case o.UNLOAD_TRANSACTION:return[];default:return e}},codex:function(e=v,t){let r,a;const i=(e,t,r,a)=>(0,n.default)({},e,{accounts:(0,n.default)({},e.accounts,{[t]:(0,n.default)({code:"0x",context:null},e.accounts[t],{storage:(0,n.default)({},(e.accounts[t]||{}).storage,{[r]:a})})})}),c=(e,t,r,a)=>{let i=e.accounts[t]||{storage:{}};return(0,n.default)({},e,{accounts:(0,n.default)({},e.accounts,{[t]:(0,n.default)({},i,{code:r,context:a})})})},l=e=>e.length>2?e.slice(0,-2).concat([e[e.length-1]]):e;switch(t.type){case o.CALL:return d("call action"),d("codex: %O",e),[...e,e[e.length-1]];case o.CREATE:return d("create action"),r=[...e,e[e.length-1]],a=r[r.length-1],void 0!==a.accounts[t.storageAddress]||t.storageAddress===s.Evm.Utils.ZERO_ADDRESS?r:(r[r.length-1]=(0,n.default)({},a,{accounts:(0,n.default)({},a.accounts,{[t.storageAddress]:{storage:{},code:"0x",context:null}})}),r);case o.STORE:{d("store action");const{address:n,slot:o,value:c}=t;return n===s.Evm.Utils.ZERO_ADDRESS?e:(r=e.slice(),a=r[r.length-1],r[r.length-1]=i(a,n,o,c),r)}case o.LOAD:{d("load action");const{address:r,slot:n,value:o}=t;return r===s.Evm.Utils.ZERO_ADDRESS?e:(a=e[e.length-1],void 0!==a.accounts[r].storage[n]?e:e.map(e=>i(e,r,n,o)))}case o.RETURN_CALL:return d("return from call"),l(e);case o.RETURN_CREATE:{d("return from create");const{address:n,code:a,context:i}=t;return r=e.slice(),r[r.length-1]=c(r[r.length-1],n,a,i),d("newState: %O",r),l(r)}case o.FAIL:return d("fail action"),(u=e).length>2?u.slice(0,-1):u;case o.RESET:return d("reset action"),[e[0]];case o.UNLOAD_TRANSACTION:return d("unload action"),v;case o.ADD_INSTANCE:{d("adding instance");const{address:r,binary:n,context:a}=t;return e.map(e=>c(e,r,n,a))}default:return e}var u}}),E=(0,i.combineReducers)({info:p,transaction:b,proc:_});t.default=E},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=d(r(19)),a=d(r(11)),i=d(r(12)),o=d(r(2)),s=d(r(0)),c=r(7),l=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t}(r(43)),u=d(r(76));function d(e){return e&&e.__esModule?e:{default:e}}(0,s.default)("debugger:solidity:reducers");const f={byCompilationId:{},byContext:{}};const p=(0,c.combineReducers)({sources:function(e=f,t){switch(t.type){case l.ADD_SOURCES:return{byCompilationId:(0,o.default)({},e.byCompilationId,(0,i.default)({},...(0,a.default)(t.sources.user).map(([e,t])=>({[e]:{byIndex:t.map(e=>e.id)}})))),byContext:(0,o.default)({},e.byContext,(0,i.default)({},...(0,a.default)(t.sources.internal).map(([e,t])=>({[e]:{byIndex:t.map(e=>e.id)}})))),byId:(0,o.default)({},e.byId,(0,i.default)({},...(0,u.default)((0,n.default)(t.sources.user).concat((0,n.default)(t.sources.internal))).map(e=>e?{[e.id]:e}:{})))};default:return e}}});const y=(0,c.combineReducers)({functionDepthStack:function(e=[],t){switch(t.type){case l.JUMP:let n=e.slice();const a="i"===(r=t.jumpDirection)?1:"o"===r?-1:0;let i=n[n.length-1],o=n.length>1?n[n.length-2]:-1;return n[n.length-1]=Math.max(i+a,o+1),n;case l.RESET:return[0];case l.UNLOAD_TRANSACTION:return[];case l.EXTERNAL_CALL:return 0===e.length?[0]:[...e,e[e.length-1]+1];case l.EXTERNAL_RETURN:return e.length>1?e.slice(0,-1):e;default:return e}var r},nextFrameIsPhantom:function(e=null,t){switch(t.type){case l.CLEAR_PHANTOM_GUARD:case l.EXTERNAL_RETURN:return!1;case l.EXTERNAL_CALL:case l.RESET:return t.guard;case l.UNLOAD_TRANSACTION:return null;default:return e}}}),h=(0,c.combineReducers)({info:p,proc:y});t.default=h},function(e,t){e.exports=require("lodash.flatten")},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n,a=r(0),i=(n=a)&&n.__esModule?n:{default:n},o=r(7),s=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t}(r(13));const c=(0,i.default)("debugger:trace:reducers");const l=(0,o.combineReducers)({steps:function(e=null,t){switch(t.type){case s.SAVE_STEPS:return t.steps;case s.UNLOAD_TRANSACTION:return c("unloading"),null;default:return e}}}),u=(0,o.combineReducers)({index:function(e=0,t){switch(t.type){case s.TOCK:return e+1;case s.RESET:case s.UNLOAD_TRANSACTION:return 0;default:return e}},finished:function(e=!1,t){switch(t.type){case s.END_OF_TRACE:return!0;case s.RESET:case s.UNLOAD_TRANSACTION:return!1;default:return e}}}),d=(0,o.combineReducers)({submoduleCount:function(e=0,t){switch(t.type){case s.SET_SUBMODULE_COUNT:return t.count;default:return e}}}),f=(0,o.combineReducers)({transaction:l,proc:u,application:d});t.default=f},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n,a=r(0),i=(n=a)&&n.__esModule?n:{default:n},o=r(7),s=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t}(r(25));const c=(0,i.default)("debugger:controller:reducers");const l=(0,o.combineReducers)({breakpoints:function(e=[],t){switch(t.type){case s.ADD_BREAKPOINT:return e.filter(e=>e.sourceId===t.breakpoint.sourceId&&e.line===t.breakpoint.line&&e.node===t.breakpoint.node).length>0?e:e.concat([t.breakpoint]);case s.REMOVE_BREAKPOINT:return e.filter(e=>e.sourceId!==t.breakpoint.sourceId||e.line!==t.breakpoint.line||e.node!==t.breakpoint.node);case s.REMOVE_ALL_BREAKPOINTS:return[];default:return e}},stepIntoInternalSources:function(e=!1,t){return t.type===s.SET_INTERNAL_STEPPING?t.status:e},isStepping:function(e=!1,t){switch(t.type){case s.START_STEPPING:return c("got step start action"),!0;case s.DONE_STEPPING:return c("got step stop action"),!1;default:return e}}});t.default=l},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n,a=r(0),i=(n=a)&&n.__esModule?n:{default:n},o=r(7),s=r(1),c=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t}(r(45));(0,i.default)("debugger:stacktrace:reducers");const l=(0,o.combineReducers)({callstack:function(e=[],t){let r;switch(t.type){case c.JUMP_IN:let{location:n,functionNode:a,contractNode:i}=t;return r={type:"internal",calledFromLocation:n,address:e[e.length-1].address,functionName:!a||"FunctionDefinition"!==a.nodeType&&"YulFunctionDefinition"!==a.nodeType?void 0:a.name,contractName:i&&"ContractDefinition"===i.nodeType?i.name:void 0},[...e,r];case c.JUMP_OUT:let o=e[e.length-1];return o&&"internal"===o.type?e.slice(0,-1):e;case c.EXTERNAL_CALL:return r={type:"external",address:t.address,calledFromLocation:t.location,functionName:void 0,contractName:t.context.contractName},[...e,r];case c.EXECUTE_RETURN:return(0,s.popNWhere)(e,t.counter,e=>"external"===e.type);case c.RESET:return[e[0]];case c.UNLOAD_TRANSACTION:return[];default:return e}},returnCounter:function(e=0,t){switch(t.type){case c.EXTERNAL_RETURN:return e+1;case c.EXECUTE_RETURN:case c.RESET:case c.UNLOAD_TRANSACTION:return 0;default:return e}},lastPosition:function(e=null,t){switch(t.type){case c.JUMP_IN:case c.JUMP_OUT:case c.ETERNAL_CALL:case c.EXTERNAL_RETURN:case c.UPDATE_POSITION:case c.EXECUTE_RETURN:const{location:r}=t;return void 0===r.source.id||r.source.internal?e:r;case c.RESET:case c.UNLOAD_TRANSACTION:return null;default:return e}},innerReturnPosition:function(e=null,t){switch(t.type){case c.EXTERNAL_RETURN:return e||t.from;case c.EXECUTE_RETURN:case c.RESET:case c.UNLOAD_TRANSACTION:return null;default:return e}},innerReturnStatus:function(e=null,t){switch(t.type){case c.EXTERNAL_RETURN:return null===e?t.status:e;case c.EXECUTE_RETURN:case c.RESET:case c.UNLOAD_TRANSACTION:return null;default:return e}},innerErrorIndex:function(e=null,t){switch(t.type){case c.EXTERNAL_RETURN:return null!==t.index?t.index:e;case c.RESET:case c.UNLOAD_TRANSACTION:return null;default:return e}}}),u=(0,o.combineReducers)({proc:l});t.default=u},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=s(r(2)),a=s(r(0)),i=r(7),o=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t}(r(41));function s(e){return e&&e.__esModule?e:{default:e}}const c=(0,a.default)("debugger:txlog:reducers"),l={byPointer:{"":{type:"transaction",actions:[]}}};const u=(0,i.combineReducers)({transactionLog:function(e=l,t){const{pointer:r,newPointer:a}=t,i=e.byPointer[r];switch(t.type){case o.RECORD_ORIGIN:return"transaction"===i.type?{byPointer:(0,n.default)({},e.byPointer,{[r]:(0,n.default)({},i,{origin:t.address})})}:(c("attempt to set origin of bad node type!"),e);case o.INTERNAL_CALL:return{byPointer:(0,n.default)({},e.byPointer,{[r]:(0,n.default)({},i,{actions:[...i.actions,a]}),[a]:{type:"callinternal",actions:[],waitingForFunctionDefinition:!0}})};case o.ABSORBED_CALL:return{byPointer:(0,n.default)({},e.byPointer,{[r]:(0,n.default)({},i,{absorbNextInternalCall:!1})})};case o.INTERNAL_RETURN:const s=(0,n.default)({},i);return"callinternal"===s.type?(s.returnKind="return",s.returnValues=t.variables,delete s.waitingForFunctionDefinition):"callexternal"===s.type?"function"===s.kind&&(s.returnValues=t.variables):c("returninternal once tx done!"),{byPointer:(0,n.default)({},e.byPointer,{[r]:s})};case o.INSTANT_EXTERNAL_CALL:case o.EXTERNAL_CALL:case o.INSTANT_CREATE:case o.CREATE:{const s=t.type===o.INSTANT_EXTERNAL_CALL||t.type===o.INSTANT_CREATE;let c=(0,n.default)({},i,{actions:[...i.actions,a]});"callexternal"===c.type&&"library"===c.kind&&(c.kind="message");const{address:l,binary:u,context:d,value:f,salt:p,isDelegate:y,decoding:h,calldata:m,status:g}=t;let b;b=t.type===o.CREATE||t.type===o.INSTANT_CREATE?d?"constructor":"unknowncreate":t.kind;const v=d?d.contractName:void 0;let _,E;"function"!==h.kind&&"constructor"!==h.kind||(_=h.abi.name,E=h.arguments);let T={type:"callexternal",address:l,contextHash:d.context||null,value:f,kind:b,isDelegate:y,functionName:_,contractName:v,arguments:E,actions:[]};return"message"===b||"library"===b?T.data=m:"unknowncreate"===b&&(T.binary=u),"constructor"!==b&&"unknowncreate"!==b||(T.salt=p),s?T.returnKind=g?"return":"revert":(T.waitingForFunctionDefinition="message"!==b,T.absorbNextInternalCall=("function"===b||"library"===b)&&t.absorbNextInternalCall),{byPointer:(0,n.default)({},e.byPointer,{[r]:c,[a]:T})}}case o.EXTERNAL_RETURN:case o.REVERT:case o.SELFDESTRUCT:{let s=(0,n.default)({},i);switch("callexternal"===s.type&&"library"===s.kind&&(s.kind="message"),t.type){case o.EXTERNAL_RETURN:s.returnKind||(s.returnKind="return");break;case o.REVERT:s.returnKind="revert",s.error=t.error;break;case o.SELFDESTRUCT:s.returnKind="selfdestruct",s.beneficiary=t.beneficiary}let l,u={byPointer:(0,n.default)({},e.byPointer,{[r]:s})};for(l=r;l.replace(/\/actions\/\d+$/,"")!==a;l=l.replace(/\/actions\/\d+$/,"")){c("currentNode!");let e=(0,n.default)({},u.byPointer[l]);e.returnKind||(e.returnKind="unwind"),delete e.waitingForFunctionDefinition,c("set currentNode!"),u.byPointer[l]=e}c("finalNode!");let d=(0,n.default)({},u.byPointer[l]);if(d.returnKind||(d.returnKind="unwind"),"function"===d.kind&&t.type===o.EXTERNAL_RETURN&&t.decodings){const e=t.decodings.find(e=>"return"===e.kind);e&&(d.returnValues=e.arguments)}if("message"===d.kind&&t.type===o.EXTERNAL_RETURN&&(d.returnData=t.returnData),"constructor"===d.kind&&t.type===o.EXTERNAL_RETURN&&t.decodings){const e=t.decodings.find(e=>"bytecode"===e.kind);e&&e.immutables&&(d.returnImmutables=e.immutables)}return delete d.waitingForFunctionDefinition,delete d.absorbNextInternalCall,c("set finalNode!"),u.byPointer[l]=d,u}case o.IDENTIFY_FUNCTION_CALL:{const{functionNode:a,contractNode:o,variables:s}=t,c=a.name||void 0,l=o&&"ContractDefinition"===o.nodeType?o.name:null;let u=(0,n.default)({},i,{waitingForFunctionDefinition:!1});return u.functionName||(u.functionName=c),u.contractName||(u.contractName=l),u.arguments||(u.arguments=s),"callexternal"===u.type&&"library"===u.kind&&(u.kind="function",delete u.data),{byPointer:(0,n.default)({},e.byPointer,{[r]:u})}}case o.RESET:return{byPointer:{"":{type:"transaction",origin:e.byPointer[""].origin,actions:[]}}};case o.UNLOAD_TRANSACTION:return l;default:return e}},currentNodePointer:function(e="",t){switch(t.type){case o.INTERNAL_CALL:case o.EXTERNAL_CALL:case o.CREATE:case o.INTERNAL_RETURN:case o.EXTERNAL_RETURN:case o.REVERT:case o.SELFDESTRUCT:return t.newPointer;case o.RESET:case o.UNLOAD_TRANSACTION:return"";default:return e}},pointerStack:function(e=[],t){switch(t.type){case o.EXTERNAL_CALL:case o.CREATE:return[...e,t.newPointer];case o.EXTERNAL_RETURN:case o.REVERT:case o.SELFDESTRUCT:return e.slice(0,-1);case o.RESET:case o.UNLOAD_TRANSACTION:return[];default:return e}}}),d=(0,i.combineReducers)({initialCall:function(e=null,t){switch(t.type){case o.EXTERNAL_CALL:case o.CREATE:return null!==e?e:t;case o.UNLOAD_TRANSACTION:return null;default:return e}}}),f=(0,i.combineReducers)({proc:u,transaction:d});t.default=f},function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r),Object.defineProperty(e,n,{enumerable:!0,get:function(){return t[r]}})}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),a=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),i=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.prototype.hasOwnProperty.call(e,r)&&n(t,e,r);return a(t,e),t},o=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),t.Errors=t.Sources=t.Shims=t.Profiler=void 0;var s=r(82);Object.defineProperty(t,"Profiler",{enumerable:!0,get:function(){return s.Profiler}}),t.Shims=i(r(102)),t.Sources=i(r(105)),t.Errors=i(r(106)),o(r(120),t)},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Profiler=void 0;var n=r(83);Object.defineProperty(t,"Profiler",{enumerable:!0,get:function(){return n.Profiler}})},function(e,t,r){"use strict";var n=this&&this.__awaiter||function(e,t,r,n){return new(r||(r=Promise))((function(a,i){function o(e){try{c(n.next(e))}catch(e){i(e)}}function s(e){try{c(n.throw(e))}catch(e){i(e)}}function c(e){var t;e.done?a(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(o,s)}c((n=n.apply(e,t||[])).next())}))},a=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.Profiler=void 0;const i=a(r(0)).default("compile-common:profiler"),o=r(84),s=r(94),c=r(95),l=r(97),u=r(100);t.Profiler=class{constructor(e){this.config=e}updated(e){return n(this,void 0,void 0,(function*(){s.options(e,["contracts_directory","contracts_build_directory"]);const{contracts_directory:t,contracts_build_directory:r}=e,n=e.files?e.files:yield o(t);return yield c.updated({paths:n,contractsBuildDirectory:r})}))}requiredSources(e){return n(this,void 0,void 0,(function*(){s.options(e,["paths","base_path","resolver","contracts_directory"]);const{resolver:t,paths:r,base_path:a,contracts_directory:c}=e;i("paths: %O",r);const d=u.convertToAbsolutePaths(r,a),f=u.convertToAbsolutePaths(yield o(c),a);return i("invoking requiredSources"),yield l.requiredSources({resolve:({filePath:e,importedFrom:r})=>n(this,void 0,void 0,(function*(){try{return yield t.resolve(e,r)}catch(e){if(e.message.startsWith("Could not find "))return;throw e}})),parseImports:this.config.parseImports,shouldIncludePath:this.config.shouldIncludePath,updatedPaths:d,allPaths:f})}))}requiredSourcesForSingleFile(e){return n(this,void 0,void 0,(function*(){s.options(e,["path","base_path","resolver"]);const{resolver:t,path:r,base_path:n}=e,a=u.convertToAbsolutePaths([r],n),i=a;return yield l.requiredSources({resolve:({filePath:e,importedFrom:r})=>t.resolve(e,r),parseImports:this.config.parseImports,shouldIncludePath:this.config.shouldIncludePath,updatedPaths:i,allPaths:a})}))}}},function(e,t,r){r(0)("contract-sources");const n=r(10),a=r(46),{promisify:i}=r(15);e.exports=(e,t)=>{const r="function"==typeof t;a.hasMagic(e)||(e=n.join(e,"**/*.{sol,vy,v.py,vyper.py,json,yul}"));return i(a)(e,{follow:!0,dot:!0}).then(e=>{if(!r)return e;t(null,e)}).catch(e=>{if(!r)throw e;t(e)})}},function(e,t,r){var n=r(10),a="win32"===process.platform,i=r(23),o=process.env.NODE_DEBUG&&/fs/.test(process.env.NODE_DEBUG);function s(e){return"function"==typeof e?e:function(){var e;if(o){var t=new Error;e=function(e){e&&(t.message=e.message,r(e=t))}}else e=r;return e;function r(e){if(e){if(process.throwDeprecation)throw e;if(!process.noDeprecation){var t="fs: missing callback "+(e.stack||e.message);process.traceDeprecation?console.trace(t):console.error(t)}}}}()}n.normalize;if(a)var c=/(.*?)(?:[\/\\]+|$)/g;else c=/(.*?)(?:[\/]+|$)/g;if(a)var l=/^(?:[a-zA-Z]:|[\\\/]{2}[^\\\/]+[\\\/][^\\\/]+)?[\\\/]*/;else l=/^[\/]*/;t.realpathSync=function(e,t){if(e=n.resolve(e),t&&Object.prototype.hasOwnProperty.call(t,e))return t[e];var r,o,s,u,d=e,f={},p={};function y(){var t=l.exec(e);r=t[0].length,o=t[0],s=t[0],u="",a&&!p[s]&&(i.lstatSync(s),p[s]=!0)}for(y();r<e.length;){c.lastIndex=r;var h=c.exec(e);if(u=o,o+=h[0],s=u+h[1],r=c.lastIndex,!(p[s]||t&&t[s]===s)){var m;if(t&&Object.prototype.hasOwnProperty.call(t,s))m=t[s];else{var g=i.lstatSync(s);if(!g.isSymbolicLink()){p[s]=!0,t&&(t[s]=s);continue}var b=null;if(!a){var v=g.dev.toString(32)+":"+g.ino.toString(32);f.hasOwnProperty(v)&&(b=f[v])}null===b&&(i.statSync(s),b=i.readlinkSync(s)),m=n.resolve(u,b),t&&(t[s]=m),a||(f[v]=b)}e=n.resolve(m,e.slice(r)),y()}}return t&&(t[d]=e),e},t.realpath=function(e,t,r){if("function"!=typeof r&&(r=s(t),t=null),e=n.resolve(e),t&&Object.prototype.hasOwnProperty.call(t,e))return process.nextTick(r.bind(null,null,t[e]));var o,u,d,f,p=e,y={},h={};function m(){var t=l.exec(e);o=t[0].length,u=t[0],d=t[0],f="",a&&!h[d]?i.lstat(d,(function(e){if(e)return r(e);h[d]=!0,g()})):process.nextTick(g)}function g(){if(o>=e.length)return t&&(t[p]=e),r(null,e);c.lastIndex=o;var n=c.exec(e);return f=u,u+=n[0],d=f+n[1],o=c.lastIndex,h[d]||t&&t[d]===d?process.nextTick(g):t&&Object.prototype.hasOwnProperty.call(t,d)?_(t[d]):i.lstat(d,b)}function b(e,n){if(e)return r(e);if(!n.isSymbolicLink())return h[d]=!0,t&&(t[d]=d),process.nextTick(g);if(!a){var o=n.dev.toString(32)+":"+n.ino.toString(32);if(y.hasOwnProperty(o))return v(null,y[o],d)}i.stat(d,(function(e){if(e)return r(e);i.readlink(d,(function(e,t){a||(y[o]=t),v(e,t)}))}))}function v(e,a,i){if(e)return r(e);var o=n.resolve(f,a);t&&(t[i]=o),_(o)}function _(t){e=n.resolve(t,e.slice(o)),m()}m()}},function(e,t,r){var n=r(87),a=r(88);e.exports=function(e){if(!e)return[];"{}"===e.substr(0,2)&&(e="\\{\\}"+e.substr(2));return function e(t,r){var i=[],o=a("{","}",t);if(!o||/\$$/.test(o.pre))return[t];var c,l=/^-?\d+\.\.-?\d+(?:\.\.-?\d+)?$/.test(o.body),d=/^[a-zA-Z]\.\.[a-zA-Z](?:\.\.-?\d+)?$/.test(o.body),m=l||d,g=o.body.indexOf(",")>=0;if(!m&&!g)return o.post.match(/,.*\}/)?(t=o.pre+"{"+o.body+s+o.post,e(t)):[t];if(m)c=o.body.split(/\.\./);else{if(1===(c=function e(t){if(!t)return[""];var r=[],n=a("{","}",t);if(!n)return t.split(",");var i=n.pre,o=n.body,s=n.post,c=i.split(",");c[c.length-1]+="{"+o+"}";var l=e(s);s.length&&(c[c.length-1]+=l.shift(),c.push.apply(c,l));return r.push.apply(r,c),r}(o.body)).length)if(1===(c=e(c[0],!1).map(f)).length)return(_=o.post.length?e(o.post,!1):[""]).map((function(e){return o.pre+c[0]+e}))}var b,v=o.pre,_=o.post.length?e(o.post,!1):[""];if(m){var E=u(c[0]),T=u(c[1]),A=Math.max(c[0].length,c[1].length),S=3==c.length?Math.abs(u(c[2])):1,R=y;T<E&&(S*=-1,R=h);var C=c.some(p);b=[];for(var O=E;R(O,T);O+=S){var L;if(d)"\\"===(L=String.fromCharCode(O))&&(L="");else if(L=String(O),C){var I=A-L.length;if(I>0){var N=new Array(I+1).join("0");L=O<0?"-"+N+L.slice(1):N+L}}b.push(L)}}else b=n(c,(function(t){return e(t,!1)}));for(var x=0;x<b.length;x++)for(var w=0;w<_.length;w++){var D=v+b[x]+_[w];(!r||m||D)&&i.push(D)}return i}(function(e){return e.split("\\\\").join(i).split("\\{").join(o).split("\\}").join(s).split("\\,").join(c).split("\\.").join(l)}(e),!0).map(d)};var i="\0SLASH"+Math.random()+"\0",o="\0OPEN"+Math.random()+"\0",s="\0CLOSE"+Math.random()+"\0",c="\0COMMA"+Math.random()+"\0",l="\0PERIOD"+Math.random()+"\0";function u(e){return parseInt(e,10)==e?parseInt(e,10):e.charCodeAt(0)}function d(e){return e.split(i).join("\\").split(o).join("{").split(s).join("}").split(c).join(",").split(l).join(".")}function f(e){return"{"+e+"}"}function p(e){return/^-?0\d/.test(e)}function y(e,t){return e<=t}function h(e,t){return e>=t}},function(e,t){e.exports=function(e,t){for(var n=[],a=0;a<e.length;a++){var i=t(e[a],a);r(i)?n.push.apply(n,i):n.push(i)}return n};var r=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)}},function(e,t,r){"use strict";function n(e,t,r){e instanceof RegExp&&(e=a(e,r)),t instanceof RegExp&&(t=a(t,r));var n=i(e,t,r);return n&&{start:n[0],end:n[1],pre:r.slice(0,n[0]),body:r.slice(n[0]+e.length,n[1]),post:r.slice(n[1]+t.length)}}function a(e,t){var r=t.match(e);return r?r[0]:null}function i(e,t,r){var n,a,i,o,s,c=r.indexOf(e),l=r.indexOf(t,c+1),u=c;if(c>=0&&l>0){for(n=[],i=r.length;u>=0&&!s;)u==c?(n.push(u),c=r.indexOf(e,u+1)):1==n.length?s=[n.pop(),l]:((a=n.pop())<i&&(i=a,o=l),l=r.indexOf(t,u+1)),u=c<l&&c>=0?c:l;n.length&&(s=[i,o])}return s}e.exports=n,n.range=i},function(e,t,r){try{var n=r(15);if("function"!=typeof n.inherits)throw"";e.exports=n.inherits}catch(t){e.exports=r(90)}},function(e,t){"function"==typeof Object.create?e.exports=function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:e.exports=function(e,t){if(t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}}},function(e,t){e.exports=require("events")},function(e,t,r){e.exports=y,y.GlobSync=h;var n=r(23),a=r(47),i=r(32),o=(i.Minimatch,r(46).Glob,r(15),r(10)),s=r(48),c=r(33),l=r(49),u=(l.alphasort,l.alphasorti,l.setopts),d=l.ownProp,f=l.childrenIgnored,p=l.isIgnored;function y(e,t){if("function"==typeof t||3===arguments.length)throw new TypeError("callback provided to sync glob\nSee: https://github.com/isaacs/node-glob/issues/167");return new h(e,t).found}function h(e,t){if(!e)throw new Error("must provide pattern");if("function"==typeof t||3===arguments.length)throw new TypeError("callback provided to sync glob\nSee: https://github.com/isaacs/node-glob/issues/167");if(!(this instanceof h))return new h(e,t);if(u(this,e,t),this.noprocess)return this;var r=this.minimatch.set.length;this.matches=new Array(r);for(var n=0;n<r;n++)this._process(this.minimatch.set[n],n,!1);this._finish()}h.prototype._finish=function(){if(s(this instanceof h),this.realpath){var e=this;this.matches.forEach((function(t,r){var n=e.matches[r]=Object.create(null);for(var i in t)try{i=e._makeAbs(i),n[a.realpathSync(i,e.realpathCache)]=!0}catch(t){if("stat"!==t.syscall)throw t;n[e._makeAbs(i)]=!0}}))}l.finish(this)},h.prototype._process=function(e,t,r){s(this instanceof h);for(var n,a=0;"string"==typeof e[a];)a++;switch(a){case e.length:return void this._processSimple(e.join("/"),t);case 0:n=null;break;default:n=e.slice(0,a).join("/")}var o,l=e.slice(a);null===n?o=".":c(n)||c(e.join("/"))?(n&&c(n)||(n="/"+n),o=n):o=n;var u=this._makeAbs(o);f(this,o)||(l[0]===i.GLOBSTAR?this._processGlobStar(n,o,u,l,t,r):this._processReaddir(n,o,u,l,t,r))},h.prototype._processReaddir=function(e,t,r,n,a,i){var s=this._readdir(r,i);if(s){for(var c=n[0],l=!!this.minimatch.negate,u=c._glob,d=this.dot||"."===u.charAt(0),f=[],p=0;p<s.length;p++){if("."!==(m=s[p]).charAt(0)||d)(l&&!e?!m.match(c):m.match(c))&&f.push(m)}var y=f.length;if(0!==y)if(1!==n.length||this.mark||this.stat){n.shift();for(p=0;p<y;p++){var h;m=f[p];h=e?[e,m]:[m],this._process(h.concat(n),a,i)}}else{this.matches[a]||(this.matches[a]=Object.create(null));for(var p=0;p<y;p++){var m=f[p];e&&(m="/"!==e.slice(-1)?e+"/"+m:e+m),"/"!==m.charAt(0)||this.nomount||(m=o.join(this.root,m)),this._emitMatch(a,m)}}}},h.prototype._emitMatch=function(e,t){if(!p(this,t)){var r=this._makeAbs(t);if(this.mark&&(t=this._mark(t)),this.absolute&&(t=r),!this.matches[e][t]){if(this.nodir){var n=this.cache[r];if("DIR"===n||Array.isArray(n))return}this.matches[e][t]=!0,this.stat&&this._stat(t)}}},h.prototype._readdirInGlobStar=function(e){if(this.follow)return this._readdir(e,!1);var t,r;try{r=n.lstatSync(e)}catch(e){if("ENOENT"===e.code)return null}var a=r&&r.isSymbolicLink();return this.symlinks[e]=a,a||!r||r.isDirectory()?t=this._readdir(e,!1):this.cache[e]="FILE",t},h.prototype._readdir=function(e,t){if(t&&!d(this.symlinks,e))return this._readdirInGlobStar(e);if(d(this.cache,e)){var r=this.cache[e];if(!r||"FILE"===r)return null;if(Array.isArray(r))return r}try{return this._readdirEntries(e,n.readdirSync(e))}catch(t){return this._readdirError(e,t),null}},h.prototype._readdirEntries=function(e,t){if(!this.mark&&!this.stat)for(var r=0;r<t.length;r++){var n=t[r];n="/"===e?e+n:e+"/"+n,this.cache[n]=!0}return this.cache[e]=t,t},h.prototype._readdirError=function(e,t){switch(t.code){case"ENOTSUP":case"ENOTDIR":var r=this._makeAbs(e);if(this.cache[r]="FILE",r===this.cwdAbs){var n=new Error(t.code+" invalid cwd "+this.cwd);throw n.path=this.cwd,n.code=t.code,n}break;case"ENOENT":case"ELOOP":case"ENAMETOOLONG":case"UNKNOWN":this.cache[this._makeAbs(e)]=!1;break;default:if(this.cache[this._makeAbs(e)]=!1,this.strict)throw t;this.silent||console.error("glob error",t)}},h.prototype._processGlobStar=function(e,t,r,n,a,i){var o=this._readdir(r,i);if(o){var s=n.slice(1),c=e?[e]:[],l=c.concat(s);this._process(l,a,!1);var u=o.length;if(!this.symlinks[r]||!i)for(var d=0;d<u;d++){if("."!==o[d].charAt(0)||this.dot){var f=c.concat(o[d],s);this._process(f,a,!0);var p=c.concat(o[d],n);this._process(p,a,!0)}}}},h.prototype._processSimple=function(e,t){var r=this._stat(e);if(this.matches[t]||(this.matches[t]=Object.create(null)),r){if(e&&c(e)&&!this.nomount){var n=/[\/\\]$/.test(e);"/"===e.charAt(0)?e=o.join(this.root,e):(e=o.resolve(this.root,e),n&&(e+="/"))}"win32"===process.platform&&(e=e.replace(/\\/g,"/")),this._emitMatch(t,e)}},h.prototype._stat=function(e){var t=this._makeAbs(e),r="/"===e.slice(-1);if(e.length>this.maxLength)return!1;if(!this.stat&&d(this.cache,t)){var a=this.cache[t];if(Array.isArray(a)&&(a="DIR"),!r||"DIR"===a)return a;if(r&&"FILE"===a)return!1}var i=this.statCache[t];if(!i){var o;try{o=n.lstatSync(t)}catch(e){if(e&&("ENOENT"===e.code||"ENOTDIR"===e.code))return this.statCache[t]=!1,!1}if(o&&o.isSymbolicLink())try{i=n.statSync(t)}catch(e){i=o}else i=o}this.statCache[t]=i;a=!0;return i&&(a=i.isDirectory()?"DIR":"FILE"),this.cache[t]=this.cache[t]||a,(!r||"FILE"!==a)&&a},h.prototype._mark=function(e){return l.mark(this,e)},h.prototype._makeAbs=function(e){return l.makeAbs(this,e)}},function(e,t,r){var n=r(50),a=Object.create(null),i=r(51);function o(e){for(var t=e.length,r=[],n=0;n<t;n++)r[n]=e[n];return r}e.exports=n((function(e,t){return a[e]?(a[e].push(t),null):(a[e]=[t],function(e){return i((function t(){var r=a[e],n=r.length,i=o(arguments);try{for(var s=0;s<n;s++)r[s].apply(null,i)}finally{r.length>n?(r.splice(0,n),process.nextTick((function(){t.apply(null,i)}))):delete a[e]}}))}(e))}))},function(e,t,r){"use strict";function n(e,t){if(null==e[t])throw new Error(`Expected parameter '${t}' not passed to function.`)}Object.defineProperty(t,"__esModule",{value:!0}),t.one=t.options=t.has=void 0,t.has=n,t.options=function(e,t){for(const r of t)n(e,r)},t.one=function(e,t){if(!t.some(t=>{try{return n(e,t),!0}catch(e){if(!e.message.includes(`Expected parameter '${t}' not passed to function.`))throw e;return!1}}))throw new Error("Expected one of the following parameters, but found none: "+t.join(", "))}},function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r),Object.defineProperty(e,n,{enumerable:!0,get:function(){return t[r]}})}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),a=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),i=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.prototype.hasOwnProperty.call(e,r)&&n(t,e,r);return a(t,e),t},o=this&&this.__awaiter||function(e,t,r,n){return new(r||(r=Promise))((function(a,i){function o(e){try{c(n.next(e))}catch(e){i(e)}}function s(e){try{c(n.throw(e))}catch(e){i(e)}}function c(e){var t;e.done?a(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(o,s)}c((n=n.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.updated=void 0;const s=i(r(10)),c=i(r(96));t.updated=function({paths:e,contractsBuildDirectory:t}){return o(this,void 0,void 0,(function*(){const r=function(e,t){const r={};let n;e.forEach(e=>{r[e]=[]});try{n=c.readdirSync(t)}catch(e){if(!e.message.includes("ENOENT: no such file or directory"))throw e;n=[]}n=n.filter(e=>".json"===s.extname(e));const a=n.map(e=>({file:e,body:c.readFileSync(s.join(t,e),"utf8")}));for(let e=0;e<a.length;e++)try{const t=JSON.parse(a[e].body);null==r[t.sourcePath]&&(r[t.sourcePath]=[]),r[t.sourcePath].push(t)}catch(t){throw t instanceof SyntaxError?new Error("Problem parsing artifact: "+a[e].file):t}return r}(e,t);return function(e,t){const r=Object.keys(e);let n;return n=r.map(e=>{try{return c.statSync(e)}catch(e){return null}}),r.map((e,r)=>{const a=n[r];if(null==a)return;const i=t[e]||0;return(a.mtime||a.ctime).getTime()>i?e:void 0}).filter(e=>e)}(r,function(e){let t={};for(const r of Object.keys(e)){const n=e[r];t[r]=n.reduce((e,t)=>{const r=new Date(t.updatedAt).getTime();return r<e?r:e},Number.MAX_SAFE_INTEGER),t[r]===Number.MAX_SAFE_INTEGER&&(t[r]=0)}return t}(r))}))}},function(e,t){e.exports=require("fs-extra")},function(e,t,r){"use strict";var n=this&&this.__awaiter||function(e,t,r,n){return new(r||(r=Promise))((function(a,i){function o(e){try{c(n.next(e))}catch(e){i(e)}}function s(e){try{c(n.throw(e))}catch(e){i(e)}}function c(e){var t;e.done?a(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(o,s)}c((n=n.apply(e,t||[])).next())}))},a=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.requiredSources=void 0;const i=a(r(0)).default("compile-common:profiler:requiredSources"),o=r(98);t.requiredSources=function({allPaths:e,updatedPaths:t,resolve:r,shouldIncludePath:a,parseImports:s}){return n(this,void 0,void 0,(function*(){const n={},c=[];if(i("allPaths: %O",e),i("updatedPaths: %O",t),t.forEach(t=>{e.includes(t)||e.push(t)}),!t.length)return{allSources:{},compilationTargets:[]};const l=yield o.resolveAllSources({resolve:r,parseImports:s,shouldIncludePath:a,paths:e});if(function(e,t){const r=e.sort(),n=t.sort();return JSON.stringify(r)===JSON.stringify(n)}(t,e)){for(const e of Object.keys(l))a(e)&&(n[e]=l[e].body);return{allSources:n,compilationTargets:Object.keys(n)}}for(const e of t)a(e)&&c.push(e);for(i("entering main loop");t.length>0;){const r=t.shift(),n=e.slice();for(;n.length>0;){const e=n.shift();if(c.includes(e))continue;i("currentFile: %s",e);const a=l[e].imports;i("imports.length: %d",a.length),a.includes(r)&&(t.push(e),c.push(e))}}i("compilationTargets: %O",c);const u=c.slice(),d=[];for(;u.length>0;){i("filesToProcess: %O",u);const e=u.shift();if(i("file: %s",e),l[e]){d.push(e);for(const t of l[e].imports)i("importPath: %s",t),d.includes(t)||u.push(t)}}i("required: %O",d);for(const e of d)a(e)&&(n[e]=l[e].body);return{allSources:n,compilationTargets:c}}))}},function(e,t,r){"use strict";var n=this&&this.__awaiter||function(e,t,r,n){return new(r||(r=Promise))((function(a,i){function o(e){try{c(n.next(e))}catch(e){i(e)}}function s(e){try{c(n.throw(e))}catch(e){i(e)}}function c(e){var t;e.done?a(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(o,s)}c((n=n.apply(e,t||[])).next())}))},a=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.resolveAllSources=void 0;const i=a(r(0)).default("compile-common:profiler:resolveAllSources"),o=r(99);t.resolveAllSources=function({resolve:e,paths:t,shouldIncludePath:r,parseImports:a}){return n(this,void 0,void 0,(function*(){const s={},c=t.slice();function l(){return n(this,void 0,void 0,(function*(){const t=[];for(;c.length;){let r,n=null;const a=c.shift();"object"==typeof a?(r=a.filePath,n=a.importedFrom):r=a,t.push(e({filePath:r,importedFrom:n}))}const n=yield Promise.all(t);for(;n.length;){const e=n.shift();if(!e||s[e.filePath])continue;const t=r(e.filePath)?yield o.getImports({source:e,parseImports:a,shouldIncludePath:r}):[];i("imports: %O",t),s[e.filePath]=Object.assign(Object.assign({},e),{imports:t});for(const r of t)s[r]||c.push({filePath:r,importedFrom:e.filePath})}}))}for(i("resolveAllSources called");c.length;)yield l();return s}))}},function(e,t,r){"use strict";var n=this&&this.__awaiter||function(e,t,r,n){return new(r||(r=Promise))((function(a,i){function o(e){try{c(n.next(e))}catch(e){i(e)}}function s(e){try{c(n.throw(e))}catch(e){i(e)}}function c(e){var t;e.done?a(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(o,s)}c((n=n.apply(e,t||[])).next())}))},a=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.getImports=void 0;const i=a(r(0)).default("compile-common:profiler:getImports");t.getImports=function({source:{filePath:e,body:t,source:r},shouldIncludePath:a,parseImports:o}){return n(this,void 0,void 0,(function*(){if(!a(e)||!o)return[];i("filePath: %s",e);const n=yield o(t);return i("imports: %O",n),(yield Promise.all(n.map(t=>r.resolveDependencyPath(e,t)))).filter(e=>e)}))}},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.convertToAbsolutePaths=void 0;const a=n(r(10)),i=r(101);t.convertToAbsolutePaths=function(e,t){return e.map(e=>a.default.isAbsolute(e)?e:i.isExplicitlyRelative(e)?a.default.resolve(a.default.join(t,e)):e).sort()}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isExplicitlyRelative=void 0,t.isExplicitlyRelative=function(e){return e.startsWith("./")||e.startsWith("../")}},function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r),Object.defineProperty(e,n,{enumerable:!0,get:function(){return t[r]}})}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),a=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),i=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.prototype.hasOwnProperty.call(e,r)&&n(t,e,r);return a(t,e),t};Object.defineProperty(t,"__esModule",{value:!0}),t.NewToLegacy=t.LegacyToNew=void 0,t.LegacyToNew=i(r(103)),t.NewToLegacy=i(r(104))},function(e,t,r){"use strict";function n(e){const{contractName:t,contract_name:r,sourcePath:n,source:i,sourceMap:o,deployedSourceMap:s,legacyAST:c,ast:l,abi:u,metadata:d,bytecode:f,deployedBytecode:p,compiler:y,devdoc:h,userdoc:m,immutableReferences:g,generatedSources:b,deployedGeneratedSources:v,db:_}=e;return{contractName:r||t,sourcePath:n,source:i,sourceMap:o,deployedSourceMap:s,legacyAST:c,ast:l,abi:u,metadata:d,bytecode:a(f),deployedBytecode:a(p),compiler:y,devdoc:h,userdoc:m,immutableReferences:g,generatedSources:b,deployedGeneratedSources:v,db:_}}function a(e){if(!e)return;if("object"==typeof e)return e;const t=[];return{bytes:e.slice(2).replace(/__[^_]+_*/g,(e,r)=>{const[,n]=e.match(/__([^_]+)_*/),a=e.length,i=r/2,o=a/2;return t.push({offsets:[i],name:n,length:o}),"0".repeat(a)}),linkReferences:t}}Object.defineProperty(t,"__esModule",{value:!0}),t.forBytecode=t.forContract=t.forContracts=void 0,t.forContracts=function(e){return Object.values(e).map(n)},t.forContract=n,t.forBytecode=a},function(e,t,r){"use strict";function n(e){if(!e)return e;if("string"==typeof e)return e;let{bytes:t,linkReferences:r}=e;return r=r||[],t=r.map(({offsets:e,length:t,name:r})=>e.map(e=>({offset:e,length:t,name:r}))).reduce((e,t)=>[...e,...t],[]).reduce((e,{offset:t,name:r,length:n})=>{const a=2*n;let i="__"+r.slice(0,a-2);for(;i.length<a;)i+="_";const o=2*t;return`${e.substring(0,o)}${i}${e.substring(o+a)}`},t),"0x"+t}Object.defineProperty(t,"__esModule",{value:!0}),t.forBytecode=t.forContract=void 0,t.forContract=function(e){const{contractName:t,sourcePath:r,source:a,sourceMap:i,deployedSourceMap:o,legacyAST:s,ast:c,abi:l,metadata:u,bytecode:d,deployedBytecode:f,compiler:p,devdoc:y,userdoc:h,immutableReferences:m,generatedSources:g,deployedGeneratedSources:b,db:v}=e;return{contract_name:t,sourcePath:r,source:a,sourceMap:i,deployedSourceMap:o,legacyAST:s,ast:c,abi:l,metadata:u,bytecode:n(d),deployedBytecode:n(f),unlinked_binary:n(d),compiler:p,devdoc:y,userdoc:h,immutableReferences:m,generatedSources:g,deployedGeneratedSources:b,db:v}},t.forBytecode=n},function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r),Object.defineProperty(e,n,{enumerable:!0,get:function(){return t[r]}})}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),a=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),i=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.prototype.hasOwnProperty.call(e,r)&&n(t,e,r);return a(t,e),t};Object.defineProperty(t,"__esModule",{value:!0}),t.collectSources=void 0;const o=i(r(10));function s(e){var t=e.replace(/\\/g,"/");return t.length>=2&&":"===t[1]&&(t=(t="/"+t).replace(":","")),t}function c(e,t){return t.endsWith(o.sep)&&(t=t.slice(0,-1)),e.startsWith(t)?e.slice(t.length):e}t.collectSources=function(e,t=[],r=""){return Object.entries(e).map(([e,t])=>({originalSourcePath:e,contents:t,sourcePath:s(c(e,r))})).map(({originalSourcePath:e,sourcePath:r,contents:n})=>({sources:{[r]:n},targets:t.includes(e)?[r]:[],originalSourcePaths:{[r]:e}})).reduce((e,t)=>({sources:Object.assign({},e.sources,t.sources),targets:[...e.targets,...t.targets],originalSourcePaths:Object.assign({},e.originalSourcePaths,t.originalSourcePaths)}),{sources:{},targets:[],originalSourcePaths:{}})}},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.CompileError=void 0;const a=n(r(107)),i=n(r(119));class o extends i.default{constructor(e){var t=e.trim()+"\n\n"+a.default.red("Compilation failed. See above.");super(e.trim()),this.message=t}}t.CompileError=o},function(e,t,r){var n=r(52);e.exports=n,r(118)()},function(e,t){var r={};e.exports=r;var n={reset:[0,0],bold:[1,22],dim:[2,22],italic:[3,23],underline:[4,24],inverse:[7,27],hidden:[8,28],strikethrough:[9,29],black:[30,39],red:[31,39],green:[32,39],yellow:[33,39],blue:[34,39],magenta:[35,39],cyan:[36,39],white:[37,39],gray:[90,39],grey:[90,39],brightRed:[91,39],brightGreen:[92,39],brightYellow:[93,39],brightBlue:[94,39],brightMagenta:[95,39],brightCyan:[96,39],brightWhite:[97,39],bgBlack:[40,49],bgRed:[41,49],bgGreen:[42,49],bgYellow:[43,49],bgBlue:[44,49],bgMagenta:[45,49],bgCyan:[46,49],bgWhite:[47,49],bgGray:[100,49],bgGrey:[100,49],bgBrightRed:[101,49],bgBrightGreen:[102,49],bgBrightYellow:[103,49],bgBrightBlue:[104,49],bgBrightMagenta:[105,49],bgBrightCyan:[106,49],bgBrightWhite:[107,49],blackBG:[40,49],redBG:[41,49],greenBG:[42,49],yellowBG:[43,49],blueBG:[44,49],magentaBG:[45,49],cyanBG:[46,49],whiteBG:[47,49]};Object.keys(n).forEach((function(e){var t=n[e],a=r[e]=[];a.open="["+t[0]+"m",a.close="["+t[1]+"m"}))},function(e,t,r){"use strict";var n=r(110),a=r(111),i=process.env,o=void 0;function s(e){return function(e){return 0!==e&&{level:e,hasBasic:!0,has256:e>=2,has16m:e>=3}}(function(e){if(!1===o)return 0;if(a("color=16m")||a("color=full")||a("color=truecolor"))return 3;if(a("color=256"))return 2;if(e&&!e.isTTY&&!0!==o)return 0;var t=o?1:0;if("win32"===process.platform){var r=n.release().split(".");return Number(process.versions.node.split(".")[0])>=8&&Number(r[0])>=10&&Number(r[2])>=10586?Number(r[2])>=14931?3:2:1}if("CI"in i)return["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI"].some((function(e){return e in i}))||"codeship"===i.CI_NAME?1:t;if("TEAMCITY_VERSION"in i)return/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(i.TEAMCITY_VERSION)?1:0;if("TERM_PROGRAM"in i){var s=parseInt((i.TERM_PROGRAM_VERSION||"").split(".")[0],10);switch(i.TERM_PROGRAM){case"iTerm.app":return s>=3?3:2;case"Hyper":return 3;case"Apple_Terminal":return 2}}return/-256(color)?$/i.test(i.TERM)?2:/^screen|^xterm|^vt100|^rxvt|color|ansi|cygwin|linux/i.test(i.TERM)||"COLORTERM"in i?1:(i.TERM,t)}(e))}a("no-color")||a("no-colors")||a("color=false")?o=!1:(a("color")||a("colors")||a("color=true")||a("color=always"))&&(o=!0),"FORCE_COLOR"in i&&(o=0===i.FORCE_COLOR.length||0!==parseInt(i.FORCE_COLOR,10)),e.exports={supportsColor:s,stdout:s(process.stdout),stderr:s(process.stderr)}},function(e,t){e.exports=require("os")},function(e,t,r){"use strict";e.exports=function(e,t){var r=(t=t||process.argv).indexOf("--"),n=/^-{1,2}/.test(e)?"":"--",a=t.indexOf(n+e);return-1!==a&&(-1===r||a<r)}},function(e,t){e.exports=function(e,t){var r="";e=(e=e||"Run the trap, drop the bass").split("");var n={a:["@","Ą","Ⱥ","Ʌ","Δ","Λ","Д"],b:["ß","Ɓ","Ƀ","ɮ","β","฿"],c:["©","Ȼ","Ͼ"],d:["Ð","Ɗ","Ԁ","ԁ","Ԃ","ԃ"],e:["Ë","ĕ","Ǝ","ɘ","Σ","ξ","Ҽ","੬"],f:["Ӻ"],g:["ɢ"],h:["Ħ","ƕ","Ң","Һ","Ӈ","Ԋ"],i:["༏"],j:["Ĵ"],k:["ĸ","Ҡ","Ӄ","Ԟ"],l:["Ĺ"],m:["ʍ","Ӎ","ӎ","Ԡ","ԡ","൩"],n:["Ñ","ŋ","Ɲ","Ͷ","Π","Ҋ"],o:["Ø","õ","ø","Ǿ","ʘ","Ѻ","ם","۝","๏"],p:["Ƿ","Ҏ"],q:["্"],r:["®","Ʀ","Ȑ","Ɍ","ʀ","Я"],s:["§","Ϟ","ϟ","Ϩ"],t:["Ł","Ŧ","ͳ"],u:["Ʊ","Ս"],v:["ט"],w:["Ш","Ѡ","Ѽ","൰"],x:["Ҳ","Ӿ","Ӽ","ӽ"],y:["¥","Ұ","Ӌ"],z:["Ƶ","ɀ"]};return e.forEach((function(e){e=e.toLowerCase();var t=n[e]||[" "],a=Math.floor(Math.random()*t.length);r+=void 0!==n[e]?n[e][a]:e})),r}},function(e,t){e.exports=function(e,t){e=e||"   he is here   ";var r={up:["̍","̎","̄","̅","̿","̑","̆","̐","͒","͗","͑","̇","̈","̊","͂","̓","̈","͊","͋","͌","̃","̂","̌","͐","̀","́","̋","̏","̒","̓","̔","̽","̉","ͣ","ͤ","ͥ","ͦ","ͧ","ͨ","ͩ","ͪ","ͫ","ͬ","ͭ","ͮ","ͯ","̾","͛","͆","̚"],down:["̖","̗","̘","̙","̜","̝","̞","̟","̠","̤","̥","̦","̩","̪","̫","̬","̭","̮","̯","̰","̱","̲","̳","̹","̺","̻","̼","ͅ","͇","͈","͉","͍","͎","͓","͔","͕","͖","͙","͚","̣"],mid:["̕","̛","̀","́","͘","̡","̢","̧","̨","̴","̵","̶","͜","͝","͞","͟","͠","͢","̸","̷","͡"," ҉"]},n=[].concat(r.up,r.down,r.mid);function a(e){return Math.floor(Math.random()*e)}function i(e){var t=!1;return n.filter((function(r){t=r===e})),t}return function(e,t){var n,o,s="";for(o in(t=t||{}).up=void 0===t.up||t.up,t.mid=void 0===t.mid||t.mid,t.down=void 0===t.down||t.down,t.size=void 0!==t.size?t.size:"maxi",e=e.split(""))if(!i(o)){switch(s+=e[o],n={up:0,down:0,mid:0},t.size){case"mini":n.up=a(8),n.mid=a(2),n.down=a(8);break;case"maxi":n.up=a(16)+3,n.mid=a(4)+1,n.down=a(64)+3;break;default:n.up=a(8)+1,n.mid=a(6)/2,n.down=a(8)+1}var c=["up","mid","down"];for(var l in c)for(var u=c[l],d=0;d<=n[u];d++)t[u]&&(s+=r[u][a(r[u].length)])}return s}(e,t)}},function(e,t){e.exports=function(e){return function(t,r,n){if(" "===t)return t;switch(r%3){case 0:return e.red(t);case 1:return e.white(t);case 2:return e.blue(t)}}}},function(e,t){e.exports=function(e){return function(t,r,n){return r%2==0?t:e.inverse(t)}}},function(e,t){e.exports=function(e){var t=["red","yellow","green","blue","magenta"];return function(r,n,a){return" "===r?r:e[t[n++%t.length]](r)}}},function(e,t){e.exports=function(e){var t=["underline","inverse","grey","yellow","red","green","blue","white","cyan","magenta","brightYellow","brightRed","brightGreen","brightBlue","brightWhite","brightCyan","brightMagenta"];return function(r,n,a){return" "===r?r:e[t[Math.round(Math.random()*(t.length-2))]](r)}}},function(e,t,r){var n=r(52);e.exports=function(){var e=function(e,t){String.prototype.__defineGetter__(e,t)};e("strip",(function(){return n.strip(this)})),e("stripColors",(function(){return n.strip(this)})),e("trap",(function(){return n.trap(this)})),e("zalgo",(function(){return n.zalgo(this)})),e("zebra",(function(){return n.zebra(this)})),e("rainbow",(function(){return n.rainbow(this)})),e("random",(function(){return n.random(this)})),e("america",(function(){return n.america(this)})),Object.keys(n.styles).forEach((function(t){e(t,(function(){return n.stylize(this,t)}))})),n.setTheme=function(t){"string"!=typeof t?function(t){var r=["__defineGetter__","__defineSetter__","__lookupGetter__","__lookupSetter__","charAt","constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf","charCodeAt","indexOf","lastIndexOf","length","localeCompare","match","repeat","replace","search","slice","split","substring","toLocaleLowerCase","toLocaleUpperCase","toLowerCase","toUpperCase","trim","trimLeft","trimRight"];Object.keys(t).forEach((function(a){if(-1!==r.indexOf(a))console.log("warn: ".red+("String.prototype"+a).magenta+" is probably something you don't want to override.  Ignoring style name");else if("string"==typeof t[a])n[a]=n[t[a]],e(a,(function(){return n[a](this)}));else{var i=function(e){for(var r=e||this,i=0;i<t[a].length;i++)r=n[t[a][i]](r);return r};e(a,i),n[a]=function(e){return i(e)}}}))}(t):console.log("colors.setTheme now only accepts an object, not a string. If you are trying to set a theme from a file, it is now your (the caller's) responsibility to require the file.  The old syntax looked like colors.setTheme(__dirname + '/../themes/generic-logging.js'); The new syntax looks like colors.setTheme(require(__dirname + '/../themes/generic-logging.js'));")}}},function(e,t,r){"use strict";class n extends Error{constructor(e){super(e),this.name=this.constructor.name}}e.exports=n},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0})}])}));
  //# sourceMappingURL=debugger.js.map