{
  "contractName": "GenericTraderProxyV1Lib",
  "abi": [],
  "metadata": "{\"compiler\":{\"version\":\"0.5.16+commit.9c3226ce\"},\"language\":\"Solidity\",\"output\":{\"abi\":[],\"devdoc\":{\"author\":\"Dolomite\",\"details\":\"Library contract for reducing code size of the GenericTraderProxyV1 contract\",\"methods\":{},\"title\":\"GenericTraderProxyV1Lib\"},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/proxies/GenericTraderProxyV1Lib.sol\":\"GenericTraderProxyV1Lib\"},\"evmVersion\":\"istanbul\",\"libraries\":{},\"optimizer\":{\"enabled\":true,\"runs\":10000},\"remappings\":[]},\"sources\":{\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/helpers/HasLiquidatorRegistry.sol\":{\"keccak256\":\"0xf7fb6d26d662f5a7ae5df8e30110664c7254f1a4969c31a3504e166018358e42\",\"urls\":[\"bzz-raw://b1a8adc3fdddce8ad10ce2420570b73218c3dd23238ab0000938051194834389\",\"dweb:/ipfs/QmPE47PxyM2xEat3xCWkiogpNRGkx26KLePGQZhGRGJpk8\"]},\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/helpers/OnlyDolomiteMargin.sol\":{\"keccak256\":\"0xe40babc0a6dd2a767d76f3e0f0a22de124c4c480f2b2227a7b924b44e57526ea\",\"urls\":[\"bzz-raw://458f7f1f16eacd4faae597090503dc1e58446e9d371640c77b2e01e3e3113f17\",\"dweb:/ipfs/QmXqTG4sWJeDh5XA286KarbqHT4qJ7m3dphS16enpqtQiX\"]},\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/interfaces/IEventEmitterRegistry.sol\":{\"keccak256\":\"0x51ae058dafa3850ba14ea352c637af48e213c4b4e69e4d398b84ec6fed91d309\",\"urls\":[\"bzz-raw://974dda23508e2d7428433db7fb280c1bc82e197fd68f9d425c57f7bf57fdf82f\",\"dweb:/ipfs/QmeTteQN1tMXChaQ4nzBvLpndVfghaoznsQDM8kAqgDeF9\"]},\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/interfaces/IExpiry.sol\":{\"keccak256\":\"0xa7b197139e570e823cab42c3b8500c9c5edc8a40110970a7d6fe60f05864ba10\",\"urls\":[\"bzz-raw://4f469be063d8f694c5277650bc53ac2c0d164f62e36c6a9ab7dad126479990a9\",\"dweb:/ipfs/Qme4sTbGi4T2QhsJSweqGzqm5rxQkypy27g1vLy8ipVijV\"]},\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/interfaces/IGenericTraderProxyBase.sol\":{\"keccak256\":\"0x2ac2830618b13f412f53c803cb8c5e79f1ea1a7da0767fb0c6430a3435153f6f\",\"urls\":[\"bzz-raw://5e128520cdac823bc7dbe5331708c650d9a4ad6a18ec3bb7d9e8739f8360cfc0\",\"dweb:/ipfs/QmcDcrnMcXUGm7NT3q6Z4idFzqcNZukrwHn5GjX44u5Win\"]},\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/interfaces/IGenericTraderProxyV1.sol\":{\"keccak256\":\"0x8341482eb0ed7eb1f81ff64556f8e2f60b4d4cd38e24aa025ec42658d1bb15c0\",\"urls\":[\"bzz-raw://75762d5b991aee081933f13fa4faf534cdcd97a68772c7c648e25132966c2847\",\"dweb:/ipfs/QmbCBqS2cmBCfyJWXDBtcnjJ7RsbUwXvuRrbSE1ny7DakH\"]},\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/interfaces/IIsolationModeUnwrapperTrader.sol\":{\"keccak256\":\"0x6b46e389ec0dff927670d76a98902763b517bf81967f9e5b73c3ff6ced2a78c8\",\"urls\":[\"bzz-raw://17cd690e571d488432192852db474420c7e8d54db3169ab9b9c7d6963e9a708a\",\"dweb:/ipfs/Qmaam6B6WyYZmrtVWkJTKc6njrbZXHnERK2ngbwyK9WckM\"]},\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/interfaces/IIsolationModeWrapperTrader.sol\":{\"keccak256\":\"0xd228f8ed8b44af8d34d6731434aa6d4146631102ec3402c5731a803393d25a9f\",\"urls\":[\"bzz-raw://186605de708fa3c5075034d0ec4e9cefacd13dd52f22ee0a485a86a4ad92d6fe\",\"dweb:/ipfs/QmcY3411rTWkk8tCGKtj7E94WC3haTbEboY1odjchra6Sn\"]},\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/interfaces/ILiquidatorAssetRegistry.sol\":{\"keccak256\":\"0x0d99615ee12fad08fbdf59a67683af9c7cdcfd2f25cf20b6767ebb6988eec514\",\"urls\":[\"bzz-raw://90230d7a44d9936cda8d1b1fef170daf91750b97d3da9634ed6c079fb8dbd15a\",\"dweb:/ipfs/QmfQxDE36en2hecxS4Y2i4BH6TsSEDEzKNxooysW4GsdKb\"]},\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/lib/AccountActionLib.sol\":{\"keccak256\":\"0x5488dd7eae5ce96e479445f19301d9dd44d292a2d6739b9da1fe948eeb41edc4\",\"urls\":[\"bzz-raw://06977e07aea4d893db696173f3ee01a84008770c4e0d81fb5eb82af3a597ceaa\",\"dweb:/ipfs/QmYiH8CsXEbHypJ2gN31LnZv2tfzd2RBuSKoRgx2EbBw26\"]},\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/lib/AccountBalanceLib.sol\":{\"keccak256\":\"0x76fd16d615fe7cfceaf775b4e6524fd0462606c802b082498c768a7a4ca01a20\",\"urls\":[\"bzz-raw://56068145e300cde1c77c22e38cb753378abf2f0d4613dcb203e33ff101f169e2\",\"dweb:/ipfs/QmXvMzr9n7vzMHdUPgnc58KX4mrbQAqkq4kDETaj5Y55ZY\"]},\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/proxies/GenericTraderProxyV1Lib.sol\":{\"keccak256\":\"0x871e2332d63dc2027b81cdc7fd0e593e482f1de670ad612ec03749d68872fe27\",\"urls\":[\"bzz-raw://45264037f7870013cd5176da854113312a106f7ebeb8bf7e4590cad9db70923d\",\"dweb:/ipfs/QmXHGnMFmqdajeF4wQGftiJvhigh4NdNskeoRnK8yXaqBh\"]},\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/interfaces/IAccountRiskOverrideSetter.sol\":{\"keccak256\":\"0x5b9fde139ddfdaae7b650b3c3f6699e0e44605f0d9d3daadc1622eb06ad4c3f8\",\"urls\":[\"bzz-raw://2dfd5af24b6de63f94519c99fd8777a264d7cd11266fa2d525c7d72d96a9c7cf\",\"dweb:/ipfs/QmPg9fjhbnmBayZMh6yTG79xsK1PWSoAHA5pfwSXfnKKjF\"]},\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/interfaces/IDolomiteMargin.sol\":{\"keccak256\":\"0x7e86ed1ed04dc205245db9f4e7cf7cca60c3bfc46c57ade8129a463780647967\",\"urls\":[\"bzz-raw://f8fbd85afd334c12bdccbb6523ebea9172b27b7b4b132c4a48b4b4dd03ceeb2b\",\"dweb:/ipfs/QmU1srfSqBTz3kw7oz1KEzfTUJvphZiE4K8MRZcy9uJjv1\"]},\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/interfaces/IERC20Detailed.sol\":{\"keccak256\":\"0x22a62e2a8155e70300773721902f4b9118e17aa0bb5d9d1b046050a014cfb223\",\"urls\":[\"bzz-raw://03af737a33c552fbe58f6f1fbd5496854fdc28dd57be4365d56663725c083a18\",\"dweb:/ipfs/QmbgLqGAQEd6tXsZB8QaPNCAMiU6nNzP75wNbKdS65BuUF\"]},\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/interfaces/IExchangeWrapper.sol\":{\"keccak256\":\"0x74799c3fac16738be41e270a70d3f7ad4f75d1dc7e5d8c58f0fe4c6128345112\",\"urls\":[\"bzz-raw://d9602af1001189d199736d17266d5fb34a32f71cd05fbcf4c0f97c0b3a642eee\",\"dweb:/ipfs/QmPto2DkZ1nKqicBMdMkaek7kGSSXqSKnf697h5zuthvsy\"]},\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/interfaces/IInterestSetter.sol\":{\"keccak256\":\"0x546825f65490a30e29d0f6446acec49c1e895ce6b33d48ca5c05092725a63a57\",\"urls\":[\"bzz-raw://6ad3013aed985bdf6e6234ae0f7f37e6bba76c3470c33bfa24678cf19b3b412c\",\"dweb:/ipfs/QmfYaSBzxGpgiHoR7ontMJY66S5L26XwkLYoEuzsEjpbQH\"]},\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/interfaces/IOracleSentinel.sol\":{\"keccak256\":\"0xa94499fda55ef112640daed2cb1d06062e72c51c7b925c323b4e0ffa9b456ce5\",\"urls\":[\"bzz-raw://18b4a16acac577590a57f34f7ec6583e3cb35f575c948abb928b308d29cac1ab\",\"dweb:/ipfs/QmR1jLkzj6w7SjrdZ7GVW4V2vofSdMJwzjTqKpeUKABvxu\"]},\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/interfaces/IPriceOracle.sol\":{\"keccak256\":\"0x3f7c3d1397390ea44c6d5e5730d49476431c3df3b28334fe38218de5edc31138\",\"urls\":[\"bzz-raw://63ebf926fca9ce33aaabaf93805686acc25daded1648d6dab59c8c4d05116918\",\"dweb:/ipfs/QmeGkDp7ycYstpfqCYBiqoCYwy876gabx8r42o5koj3H5A\"]},\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/lib/Account.sol\":{\"keccak256\":\"0x2059276ea5e478bd5ac7f2712e7b1b6c85d291c647a54b264909044844828e67\",\"urls\":[\"bzz-raw://f153777051d12131b13a57e5c3af10a2670927cfc7d22c9519ab20c9b4b9bc89\",\"dweb:/ipfs/QmQMP3qS5xDAVGYKDfNkbkSqBKozQGQsGqX4e8VyjRtxPS\"]},\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/lib/Actions.sol\":{\"keccak256\":\"0x7b2fcf441c034952dd042b6c8b20b148359db771e7c9ac07d06369560a9f0301\",\"urls\":[\"bzz-raw://84665ee4a780360fe6160d197ba98f0bf0ab0d7c6ad87bfed6226bf2f88d8d30\",\"dweb:/ipfs/QmRDfRdAd8hSXeu4SAeeYKkKoXBhStu7n4uReYBce2JD5Z\"]},\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/lib/Bits.sol\":{\"keccak256\":\"0x6d9a641163b2dd25e648c65f5d9e4949a57938e29ddc4c9dddefd74a9964aeef\",\"urls\":[\"bzz-raw://67e5a04ed4055faafbc100d6ccca9c54448ed378a1a8c71171562edda7bcbf7c\",\"dweb:/ipfs/QmYRikK3Xbgiq3UBJkgoo2zNUSSrShVabpRHmQj6iQHhrc\"]},\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/lib/Cache.sol\":{\"keccak256\":\"0xe57c80a7621a77fcb2acb9f883fb5248e71a6dce03bc2db56df0db3fee332950\",\"urls\":[\"bzz-raw://28e221c04629674490b9a0041d4f9a5f15e669dc0cc192a5df6e2c701c36369f\",\"dweb:/ipfs/QmaL3oh8c7v9cx91pB175pyCEuzxnhNTab4UxmBMsDYfUx\"]},\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/lib/Decimal.sol\":{\"keccak256\":\"0xd9a348c2b1eec076609ba12bbec6b9c2e4ea135790a7ef4f5411feb050af2144\",\"urls\":[\"bzz-raw://d5bcff29e47d5cd02d7a9966e9f44c46ccbb4f0e4adfc4b0b86646880677db39\",\"dweb:/ipfs/QmRKfJD4FFM1AvTynSFNx1NcDg94o9SAcjz7dvMaJCfecp\"]},\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/lib/DolomiteMarginMath.sol\":{\"keccak256\":\"0x53f205f6a779d579be29faa9412c806a892b3e605fff092dfd9d14d936fa019f\",\"urls\":[\"bzz-raw://0ff936f89602a63b8e6a4eb4ce8f87673c0f45b7ce29694920905a3f0b5a6a69\",\"dweb:/ipfs/QmbYME9BeEvPC1ndV8EaUDX5fDMghLc3rocNUxFtgHmg8m\"]},\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/lib/EnumerableSet.sol\":{\"keccak256\":\"0x41a3460e34b7b8635d936e35e6568ceb5354b638f53b884530e0d4875fa0f151\",\"urls\":[\"bzz-raw://d1a5ba866ee95d455afe5075dadd91fc71c2806371f2c1b358a1f67c632bb0df\",\"dweb:/ipfs/QmW4qCjmsG8J3UJv97GwDLDM7wt1K4yLDKAwzWMY7TFYi5\"]},\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/lib/Events.sol\":{\"keccak256\":\"0x2345dcc1ebf53a3d5449dab083b1fb90b5362dae692f8ff3ad00078862894e9b\",\"urls\":[\"bzz-raw://ebd34c557c06caf0696774844f0ca9746412ecc452bdd978b3bca0fd71aefbde\",\"dweb:/ipfs/QmcwXXKgv77DqfhxABRg85WR6RBPTLmge5vJGp99o9kFf8\"]},\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/lib/Interest.sol\":{\"keccak256\":\"0x141a0ecb4a746f0e5767df4b99dbe33c6362df507ae9d5c02da1c1c17bc26df3\",\"urls\":[\"bzz-raw://9ff03e64a8ce5231acde07788624bf8c7a8ff55d90b157fa32f62fa887a0eff0\",\"dweb:/ipfs/QmUVxxWeE954RDXbmHJAYnHsXcit6rSXGqZUigu8t9oH2z\"]},\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/lib/Monetary.sol\":{\"keccak256\":\"0x5257274f2d4d3605f3e97ec45fb902111fe9a22506f0b4cf308ea933bc81bfe2\",\"urls\":[\"bzz-raw://85b8023b78805063a2ec8d376f1f5983994eabd96efd8ceadb0224dbb71c5678\",\"dweb:/ipfs/QmaDhzCzRqsuHuJfhToEC4pATQHwhh7yWWsjwfuRzFT1kG\"]},\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/lib/Require.sol\":{\"keccak256\":\"0x05a2a90b41b6a5f42f0a72da63d015fb0b406a9ba2172823352e522e8bf3a606\",\"urls\":[\"bzz-raw://19883f0c6d33266f756ec5c3d17539524aa24b993c46c33f8400801d09373a6c\",\"dweb:/ipfs/QmYX2fwK3vQQDSZLMrc5wMfeb8RWrcC9CGX8XECLty8QDk\"]},\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/lib/Storage.sol\":{\"keccak256\":\"0x9c27f3cd52af28c9b6bca18097b1793f114d08284d78417467d0d05f67e9e2a9\",\"urls\":[\"bzz-raw://d1ed0e7a7f76d59f30572996d4e164ab8fb5b2ec4bfca127983f9e936b904813\",\"dweb:/ipfs/QmePVYbgrY8Yw3Vf76pmEvE9pX916Jaa9we4kjM8tGM4J1\"]},\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/lib/Time.sol\":{\"keccak256\":\"0x87ee8d3c1d6e315a116426d8c8fc6f083e220fd14dda27fad4e8d7cab3dc7305\",\"urls\":[\"bzz-raw://7c20f2c52da682c3b5917fb6a19e81f43699b1d13c62b569ed723f34da72e766\",\"dweb:/ipfs/QmbXWYXi67nHBVNDKYUpo2E9ZaEVcHLvmXQkpYLMm1d5Vm\"]},\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/lib/Token.sol\":{\"keccak256\":\"0x095b5f8eb3665f6e246200311efc8a654fa3e90f9a1a522e27a4d089e8ab3917\",\"urls\":[\"bzz-raw://5db812b752a03d601d424e6e21be38153477082af0acf51b5c98eefa5553ed18\",\"dweb:/ipfs/QmbE549QUXYTurpx8hSMLBJvuBpfYqyNE6FBCgHJDY8PLf\"]},\"/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/lib/Types.sol\":{\"keccak256\":\"0xe1bab8c8799d83e86c7a49aaf815d8e3bc8d09562d46d44d921500db5e98de0e\",\"urls\":[\"bzz-raw://8ea3d0cc4fdab6dd9bba545a792170f939b342d8d1a7051c1c6365009af72658\",\"dweb:/ipfs/QmaLJgbavu88eEit6JPqfWnw6NmGBDZfveMXxumgWywBFG\"]},\"@openzeppelin/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzz-raw://31113152e1ddb78fe7a4197f247591ca894e93f916867beb708d8e747b6cc74f\",\"dweb:/ipfs/QmbZaJyXdpsYGykVhHH9qpVGQg9DGCxE2QufbCUy3daTgq\"]},\"@openzeppelin/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0xe5bb0f57cff3e299f360052ba50f1ea0fff046df2be070b6943e0e3c3fdad8a9\",\"urls\":[\"bzz-raw://59fd025151435da35faa8093a5c7a17de02de9d08ad27275c5cdf05050820d91\",\"dweb:/ipfs/QmQMvwEcPhoRXzbXyrdoeRtvLoifUW9Qh7Luho7bmUPRkc\"]},\"@openzeppelin/contracts/utils/ReentrancyGuard.sol\":{\"keccak256\":\"0xb63221b23818d622bfd83d18e0968307e4fcb7a35536bdceded76e1cf8349acd\",\"urls\":[\"bzz-raw://44e1e8c22362c4708a8c3362735f1465f5b05e2f7315e16c7010d694ce019d73\",\"dweb:/ipfs/QmWj9g8X1hxkXRre2kwkEjLBetjuzmSbWHD81bsSojnBkS\"]}},\"version\":1}",
  "bytecode": "0x611980610026600b82828239805160001a60731461001957fe5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600436106100405760003560e01c80636183f6e814610045578063bd742ba514610067575b600080fd5b81801561005157600080fd5b5061006561006036600461135e565b610087565b005b81801561007357600080fd5b50610065610082366004611289565b610131565b600181600281111561009557fe5b141561012c576020808401518351918401516040517f62eeb68e00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff909216926362eeb68e926100f99290600401611653565b600060405180830381600087803b15801561011357600080fd5b505af1158015610127573d6000803e3d6000fd5b505050505b505050565b6020808701518651918701516040517f255a3bf700000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9092169263255a3bf7926101939290899089906004016116e7565b600060405180830381600087803b1580156101ad57600080fd5b505af11580156101c1573d6000803e3d6000fd5b50600292506101ce915050565b8160028111156101da57fe5b14156101ec576101ec868686856101f4565b505050505050565b6101fc610d39565b610204610d5e565b856000015173ffffffffffffffffffffffffffffffffffffffff1663c190c2ec868660008151811061023257fe5b60200260200101516040518363ffffffff1660e01b8152600401610257929190611753565b604080518083038186803b15801561026e57600080fd5b505afa158015610282573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506102a691908101906113cc565b905060405180604001604052806102ca8860c0015184610b8c90919063ffffffff16565b8152602001876000015173ffffffffffffffffffffffffffffffffffffffff166347d1b53c88886000815181106102fd57fe5b60200260200101516040518363ffffffff1660e01b8152600401610322929190611753565b604080518083038186803b15801561033957600080fd5b505afa15801561034d573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525061037191908101906113ae565b81525091505061037f610d39565b610387610d5e565b866000015173ffffffffffffffffffffffffffffffffffffffff1663c190c2ec87876001895103815181106103b857fe5b60200260200101516040518363ffffffff1660e01b81526004016103dd929190611753565b604080518083038186803b1580156103f457600080fd5b505afa158015610408573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525061042c91908101906113cc565b905060405180604001604052806104508960e0015184610b8c90919063ffffffff16565b8152602001886000015173ffffffffffffffffffffffffffffffffffffffff166347d1b53c898960018b51038151811061048657fe5b60200260200101516040518363ffffffff1660e01b81526004016104ab929190611753565b604080518083038186803b1580156104c257600080fd5b505afa1580156104d6573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506104fa91908101906113ae565b815250915050610508610d39565b610510610d5e565b876000015173ffffffffffffffffffffffffffffffffffffffff1663c190c2ec88876040015160008151811061054257fe5b6020026020010151600001516040518363ffffffff1660e01b815260040161056b929190611753565b604080518083038186803b15801561058257600080fd5b505afa158015610596573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506105ba91908101906113cc565b905060405180604001604052806105df8a610100015184610b8c90919063ffffffff16565b8152602001896000015173ffffffffffffffffffffffffffffffffffffffff166347d1b53c8a896040015160008151811061061657fe5b6020026020010151600001516040518363ffffffff1660e01b815260040161063f929190611753565b604080518083038186803b15801561065657600080fd5b505afa15801561066a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525061068e91908101906113ae565b81525091505086604001511561091357866020015173ffffffffffffffffffffffffffffffffffffffff16632b1ca6cd876000015188602001518a6000015173ffffffffffffffffffffffffffffffffffffffff1663062bd3e98a6000815181106106f557fe5b60200260200101516040518263ffffffff1660e01b8152600401610719919061176e565b60206040518083038186803b15801561073157600080fd5b505afa158015610745573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506107699190810190611263565b8b6000015173ffffffffffffffffffffffffffffffffffffffff1663062bd3e98b60018d51038151811061079957fe5b60200260200101516040518263ffffffff1660e01b81526004016107bd919061176e565b60206040518083038186803b1580156107d557600080fd5b505afa1580156107e9573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525061080d9190810190611263565b8c6000015173ffffffffffffffffffffffffffffffffffffffff1663062bd3e98b6040015160008151811061083e57fe5b6020026020010151600001516040518263ffffffff1660e01b8152600401610866919061176e565b60206040518083038186803b15801561087e57600080fd5b505afa158015610892573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506108b69190810190611263565b8989896040518963ffffffff1660e01b81526004016108dc98979695949392919061166e565b600060405180830381600087803b1580156108f657600080fd5b505af115801561090a573d6000803e3d6000fd5b50505050610127565b866020015173ffffffffffffffffffffffffffffffffffffffff16630f680cc2876000015188602001518a6000015173ffffffffffffffffffffffffffffffffffffffff1663062bd3e98a60008151811061096a57fe5b60200260200101516040518263ffffffff1660e01b815260040161098e919061176e565b60206040518083038186803b1580156109a657600080fd5b505afa1580156109ba573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506109de9190810190611263565b8b6000015173ffffffffffffffffffffffffffffffffffffffff1663062bd3e98b60018d510381518110610a0e57fe5b60200260200101516040518263ffffffff1660e01b8152600401610a32919061176e565b60206040518083038186803b158015610a4a57600080fd5b505afa158015610a5e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250610a829190810190611263565b8c6000015173ffffffffffffffffffffffffffffffffffffffff1663062bd3e98b60400151600081518110610ab357fe5b6020026020010151600001516040518263ffffffff1660e01b8152600401610adb919061176e565b60206040518083038186803b158015610af357600080fd5b505afa158015610b07573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250610b2b9190810190611263565b8989896040518963ffffffff1660e01b8152600401610b5198979695949392919061166e565b600060405180830381600087803b158015610b6b57600080fd5b505af1158015610b7f573d6000803e3d6000fd5b5050505050505050505050565b610b94610d5e565b610ba683610ba184610baf565b610bd7565b90505b92915050565b610bb7610d5e565b50604080518082019091528151158152602080830151908201525b919050565b610bdf610d5e565b610be7610d5e565b8251845115159015151415610c1a5783511515815260208085015190840151610c109190610c69565b6020820152610ba6565b8260200151846020015110610c435783511515815260208085015190840151610c109190610cb1565b82511515815260208084015190850151610c5d9190610cb1565b60208201529392505050565b600082820183811015610ba6576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610ca890611743565b60405180910390fd5b6000610ba683836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f77000081525060008184841115610d2c576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610ca89190611732565b50508183035b9392505050565b6040518060400160405280610d4c610d5e565b8152602001610d59610d5e565b905290565b604080518082019091526000808252602082015290565b8035610ba9816118eb565b8051610ba9816118eb565b600082601f830112610d9c57600080fd5b8135610daf610daa826117a3565b61177c565b81815260209384019390925082018360005b83811015610ded5781358601610dd788826110b9565b8452506020928301929190910190600101610dc1565b5050505092915050565b600082601f830112610e0857600080fd5b8135610e16610daa826117a3565b91508181835260208401935060208101905083856040840282011115610e3b57600080fd5b60005b83811015610ded5781610e518882611140565b84525060209092019160409190910190600101610e3e565b600082601f830112610e7a57600080fd5b8135610e88610daa826117a3565b91508181835260208401935060208101905083856020840282011115610ead57600080fd5b60005b83811015610ded5781610ec3888261124d565b8452506020928301929190910190600101610eb0565b8035610ba9816118ff565b8051610ba9816118ff565b600082601f830112610f0057600080fd5b8135610f0e610daa826117c4565b91508082526020830160208301858383011115610f2a57600080fd5b610f3583828461187e565b50505092915050565b8035610ba981611908565b8035610ba981611911565b8035610ba98161191e565b60006101808284031215610f7257600080fd5b610f7d61012061177c565b90506000610f8b8484610f3e565b8252506020610f9c84848301610f3e565b6020830152506040610fb084828501610ed9565b6040830152506060610fc48482850161124d565b6060830152506080610fd88482850161124d565b60808301525060a0610fec8482850161124d565b60a08301525060c0611000848285016111dd565b60c083015250610100611015848285016111dd565b60e08301525061014061102a848285016111dd565b6101008301525092915050565b60006040828403121561104957600080fd5b611053604061177c565b905060006110618484610d75565b82525060206110728484830161124d565b60208301525092915050565b60006040828403121561109057600080fd5b61109a604061177c565b905060006110a88484610ee4565b825250602061107284848301611242565b6000608082840312156110cb57600080fd5b6110d5608061177c565b905060006110e38484610f54565b82525060206110f48484830161124d565b602083015250604061110884828501610d75565b604083015250606082013567ffffffffffffffff81111561112857600080fd5b61113484828501610eef565b60608301525092915050565b60006040828403121561115257600080fd5b61115c604061177c565b90506000611061848461124d565b60006060828403121561117c57600080fd5b611186606061177c565b90506000611194848461124d565b82525060206111a58484830161124d565b602083015250604082013567ffffffffffffffff8111156111c557600080fd5b6111d184828501610df7565b60408301525092915050565b6000604082840312156111ef57600080fd5b6111f9604061177c565b905060006110618484610ed9565b60006040828403121561121957600080fd5b611223604061177c565b905060006112318484610ee4565b825250602061107284848301611258565b8051610ba98161192b565b8035610ba981611934565b8051610ba981611934565b60006020828403121561127557600080fd5b60006112818484610d80565b949350505050565b60008060008060008061024087890312156112a357600080fd5b60006112af8989610f5f565b9650506101806112c189828a01611037565b9550506101c087013567ffffffffffffffff8111156112df57600080fd5b6112eb89828a01610e69565b9450506101e087013567ffffffffffffffff81111561130957600080fd5b61131589828a01610d8b565b93505061020087013567ffffffffffffffff81111561133357600080fd5b61133f89828a0161116a565b92505061022061135189828a01610f49565b9150509295509295509295565b60008060006101e0848603121561137457600080fd5b60006113808686610f5f565b93505061018061139286828701611037565b9250506101c06113a486828701610f49565b9150509250925092565b6000604082840312156113c057600080fd5b6000611281848461107e565b6000604082840312156113de57600080fd5b60006112818484611207565b6000610ba683836115d5565b6000611402838361164a565b505060200190565b6114138161181d565b82525050565b600061142482611810565b61142e8185611814565b9350836020820285016114408561180a565b8060005b8581101561147a578484038952815161145d85826113ea565b94506114688361180a565b60209a909a0199925050600101611444565b5091979650505050505050565b600061149282611810565b61149c8185611814565b93506114a78361180a565b8060005b838110156114d55781516114bf88826113f6565b97506114ca8361180a565b9250506001016114ab565b509495945050505050565b61141381611828565b60006114f482611810565b6114fe8185611814565b935061150e81856020860161188a565b611517816118b6565b9093019392505050565b61141381611873565b6000611537601b83611814565b7f536166654d6174683a206164646974696f6e206f766572666c6f770000000000815260200192915050565b805160808301906115748482611630565b50602082015161158760408501826115b1565b50505050565b8051604083019061159e848261140a565b506020820151611587602085018261164a565b805160408301906115c284826114e0565b5060208201516115876020850182611641565b805160009060808401906115e98582611521565b5060208301516115fc602086018261164a565b50604083015161160f604086018261140a565b506060830151848203606086015261162782826114e9565b95945050505050565b8051604083019061159e84826114e0565b61141381611842565b61141381611870565b60408101611661828561140a565b610d32602083018461164a565b610220810161167d828b61140a565b61168a602083018a61164a565b611697604083018961140a565b6116a4606083018861140a565b6116b1608083018761140a565b6116be60a0830186611563565b6116cc610120830185611563565b6116da6101a0830184611563565b9998505050505050505050565b608081016116f5828761140a565b611702602083018661164a565b81810360408301526117148185611487565b905081810360608301526117288184611419565b9695505050505050565b60208082528101610ba681846114e9565b60208082528101610ba98161152a565b60608101611761828561158d565b610d32604083018461164a565b60208101610ba9828461164a565b60405181810167ffffffffffffffff8111828210171561179b57600080fd5b604052919050565b600067ffffffffffffffff8211156117ba57600080fd5b5060209081020190565b600067ffffffffffffffff8211156117db57600080fd5b506020601f919091017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0160190565b60200190565b5190565b90815260200190565b6000610ba982611857565b151590565b6000610ba98261181d565b80610bd2816118de565b6fffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff1690565b90565b6000610ba982611838565b82818337506000910152565b60005b838110156118a557818101518382015260200161188d565b838111156115875750506000910152565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01690565b600481106118e857fe5b50565b6118f48161181d565b81146118e857600080fd5b6118f481611828565b6118f48161182d565b600381106118e857600080fd5b600481106118e857600080fd5b6118f481611842565b6118f48161187056fea365627a7a72315820e5c4353739728077870f6acae15a247fd7b0bc6b6f65f8fd8eb8e3257ebd96f26c6578706572696d656e74616cf564736f6c63430005100040",
  "deployedBytecode": "0x73000000000000000000000000000000000000000030146080604052600436106100405760003560e01c80636183f6e814610045578063bd742ba514610067575b600080fd5b81801561005157600080fd5b5061006561006036600461135e565b610087565b005b81801561007357600080fd5b50610065610082366004611289565b610131565b600181600281111561009557fe5b141561012c576020808401518351918401516040517f62eeb68e00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff909216926362eeb68e926100f99290600401611653565b600060405180830381600087803b15801561011357600080fd5b505af1158015610127573d6000803e3d6000fd5b505050505b505050565b6020808701518651918701516040517f255a3bf700000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9092169263255a3bf7926101939290899089906004016116e7565b600060405180830381600087803b1580156101ad57600080fd5b505af11580156101c1573d6000803e3d6000fd5b50600292506101ce915050565b8160028111156101da57fe5b14156101ec576101ec868686856101f4565b505050505050565b6101fc610d39565b610204610d5e565b856000015173ffffffffffffffffffffffffffffffffffffffff1663c190c2ec868660008151811061023257fe5b60200260200101516040518363ffffffff1660e01b8152600401610257929190611753565b604080518083038186803b15801561026e57600080fd5b505afa158015610282573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506102a691908101906113cc565b905060405180604001604052806102ca8860c0015184610b8c90919063ffffffff16565b8152602001876000015173ffffffffffffffffffffffffffffffffffffffff166347d1b53c88886000815181106102fd57fe5b60200260200101516040518363ffffffff1660e01b8152600401610322929190611753565b604080518083038186803b15801561033957600080fd5b505afa15801561034d573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525061037191908101906113ae565b81525091505061037f610d39565b610387610d5e565b866000015173ffffffffffffffffffffffffffffffffffffffff1663c190c2ec87876001895103815181106103b857fe5b60200260200101516040518363ffffffff1660e01b81526004016103dd929190611753565b604080518083038186803b1580156103f457600080fd5b505afa158015610408573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525061042c91908101906113cc565b905060405180604001604052806104508960e0015184610b8c90919063ffffffff16565b8152602001886000015173ffffffffffffffffffffffffffffffffffffffff166347d1b53c898960018b51038151811061048657fe5b60200260200101516040518363ffffffff1660e01b81526004016104ab929190611753565b604080518083038186803b1580156104c257600080fd5b505afa1580156104d6573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506104fa91908101906113ae565b815250915050610508610d39565b610510610d5e565b876000015173ffffffffffffffffffffffffffffffffffffffff1663c190c2ec88876040015160008151811061054257fe5b6020026020010151600001516040518363ffffffff1660e01b815260040161056b929190611753565b604080518083038186803b15801561058257600080fd5b505afa158015610596573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506105ba91908101906113cc565b905060405180604001604052806105df8a610100015184610b8c90919063ffffffff16565b8152602001896000015173ffffffffffffffffffffffffffffffffffffffff166347d1b53c8a896040015160008151811061061657fe5b6020026020010151600001516040518363ffffffff1660e01b815260040161063f929190611753565b604080518083038186803b15801561065657600080fd5b505afa15801561066a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525061068e91908101906113ae565b81525091505086604001511561091357866020015173ffffffffffffffffffffffffffffffffffffffff16632b1ca6cd876000015188602001518a6000015173ffffffffffffffffffffffffffffffffffffffff1663062bd3e98a6000815181106106f557fe5b60200260200101516040518263ffffffff1660e01b8152600401610719919061176e565b60206040518083038186803b15801561073157600080fd5b505afa158015610745573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506107699190810190611263565b8b6000015173ffffffffffffffffffffffffffffffffffffffff1663062bd3e98b60018d51038151811061079957fe5b60200260200101516040518263ffffffff1660e01b81526004016107bd919061176e565b60206040518083038186803b1580156107d557600080fd5b505afa1580156107e9573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525061080d9190810190611263565b8c6000015173ffffffffffffffffffffffffffffffffffffffff1663062bd3e98b6040015160008151811061083e57fe5b6020026020010151600001516040518263ffffffff1660e01b8152600401610866919061176e565b60206040518083038186803b15801561087e57600080fd5b505afa158015610892573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506108b69190810190611263565b8989896040518963ffffffff1660e01b81526004016108dc98979695949392919061166e565b600060405180830381600087803b1580156108f657600080fd5b505af115801561090a573d6000803e3d6000fd5b50505050610127565b866020015173ffffffffffffffffffffffffffffffffffffffff16630f680cc2876000015188602001518a6000015173ffffffffffffffffffffffffffffffffffffffff1663062bd3e98a60008151811061096a57fe5b60200260200101516040518263ffffffff1660e01b815260040161098e919061176e565b60206040518083038186803b1580156109a657600080fd5b505afa1580156109ba573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506109de9190810190611263565b8b6000015173ffffffffffffffffffffffffffffffffffffffff1663062bd3e98b60018d510381518110610a0e57fe5b60200260200101516040518263ffffffff1660e01b8152600401610a32919061176e565b60206040518083038186803b158015610a4a57600080fd5b505afa158015610a5e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250610a829190810190611263565b8c6000015173ffffffffffffffffffffffffffffffffffffffff1663062bd3e98b60400151600081518110610ab357fe5b6020026020010151600001516040518263ffffffff1660e01b8152600401610adb919061176e565b60206040518083038186803b158015610af357600080fd5b505afa158015610b07573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250610b2b9190810190611263565b8989896040518963ffffffff1660e01b8152600401610b5198979695949392919061166e565b600060405180830381600087803b158015610b6b57600080fd5b505af1158015610b7f573d6000803e3d6000fd5b5050505050505050505050565b610b94610d5e565b610ba683610ba184610baf565b610bd7565b90505b92915050565b610bb7610d5e565b50604080518082019091528151158152602080830151908201525b919050565b610bdf610d5e565b610be7610d5e565b8251845115159015151415610c1a5783511515815260208085015190840151610c109190610c69565b6020820152610ba6565b8260200151846020015110610c435783511515815260208085015190840151610c109190610cb1565b82511515815260208084015190850151610c5d9190610cb1565b60208201529392505050565b600082820183811015610ba6576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610ca890611743565b60405180910390fd5b6000610ba683836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f77000081525060008184841115610d2c576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610ca89190611732565b50508183035b9392505050565b6040518060400160405280610d4c610d5e565b8152602001610d59610d5e565b905290565b604080518082019091526000808252602082015290565b8035610ba9816118eb565b8051610ba9816118eb565b600082601f830112610d9c57600080fd5b8135610daf610daa826117a3565b61177c565b81815260209384019390925082018360005b83811015610ded5781358601610dd788826110b9565b8452506020928301929190910190600101610dc1565b5050505092915050565b600082601f830112610e0857600080fd5b8135610e16610daa826117a3565b91508181835260208401935060208101905083856040840282011115610e3b57600080fd5b60005b83811015610ded5781610e518882611140565b84525060209092019160409190910190600101610e3e565b600082601f830112610e7a57600080fd5b8135610e88610daa826117a3565b91508181835260208401935060208101905083856020840282011115610ead57600080fd5b60005b83811015610ded5781610ec3888261124d565b8452506020928301929190910190600101610eb0565b8035610ba9816118ff565b8051610ba9816118ff565b600082601f830112610f0057600080fd5b8135610f0e610daa826117c4565b91508082526020830160208301858383011115610f2a57600080fd5b610f3583828461187e565b50505092915050565b8035610ba981611908565b8035610ba981611911565b8035610ba98161191e565b60006101808284031215610f7257600080fd5b610f7d61012061177c565b90506000610f8b8484610f3e565b8252506020610f9c84848301610f3e565b6020830152506040610fb084828501610ed9565b6040830152506060610fc48482850161124d565b6060830152506080610fd88482850161124d565b60808301525060a0610fec8482850161124d565b60a08301525060c0611000848285016111dd565b60c083015250610100611015848285016111dd565b60e08301525061014061102a848285016111dd565b6101008301525092915050565b60006040828403121561104957600080fd5b611053604061177c565b905060006110618484610d75565b82525060206110728484830161124d565b60208301525092915050565b60006040828403121561109057600080fd5b61109a604061177c565b905060006110a88484610ee4565b825250602061107284848301611242565b6000608082840312156110cb57600080fd5b6110d5608061177c565b905060006110e38484610f54565b82525060206110f48484830161124d565b602083015250604061110884828501610d75565b604083015250606082013567ffffffffffffffff81111561112857600080fd5b61113484828501610eef565b60608301525092915050565b60006040828403121561115257600080fd5b61115c604061177c565b90506000611061848461124d565b60006060828403121561117c57600080fd5b611186606061177c565b90506000611194848461124d565b82525060206111a58484830161124d565b602083015250604082013567ffffffffffffffff8111156111c557600080fd5b6111d184828501610df7565b60408301525092915050565b6000604082840312156111ef57600080fd5b6111f9604061177c565b905060006110618484610ed9565b60006040828403121561121957600080fd5b611223604061177c565b905060006112318484610ee4565b825250602061107284848301611258565b8051610ba98161192b565b8035610ba981611934565b8051610ba981611934565b60006020828403121561127557600080fd5b60006112818484610d80565b949350505050565b60008060008060008061024087890312156112a357600080fd5b60006112af8989610f5f565b9650506101806112c189828a01611037565b9550506101c087013567ffffffffffffffff8111156112df57600080fd5b6112eb89828a01610e69565b9450506101e087013567ffffffffffffffff81111561130957600080fd5b61131589828a01610d8b565b93505061020087013567ffffffffffffffff81111561133357600080fd5b61133f89828a0161116a565b92505061022061135189828a01610f49565b9150509295509295509295565b60008060006101e0848603121561137457600080fd5b60006113808686610f5f565b93505061018061139286828701611037565b9250506101c06113a486828701610f49565b9150509250925092565b6000604082840312156113c057600080fd5b6000611281848461107e565b6000604082840312156113de57600080fd5b60006112818484611207565b6000610ba683836115d5565b6000611402838361164a565b505060200190565b6114138161181d565b82525050565b600061142482611810565b61142e8185611814565b9350836020820285016114408561180a565b8060005b8581101561147a578484038952815161145d85826113ea565b94506114688361180a565b60209a909a0199925050600101611444565b5091979650505050505050565b600061149282611810565b61149c8185611814565b93506114a78361180a565b8060005b838110156114d55781516114bf88826113f6565b97506114ca8361180a565b9250506001016114ab565b509495945050505050565b61141381611828565b60006114f482611810565b6114fe8185611814565b935061150e81856020860161188a565b611517816118b6565b9093019392505050565b61141381611873565b6000611537601b83611814565b7f536166654d6174683a206164646974696f6e206f766572666c6f770000000000815260200192915050565b805160808301906115748482611630565b50602082015161158760408501826115b1565b50505050565b8051604083019061159e848261140a565b506020820151611587602085018261164a565b805160408301906115c284826114e0565b5060208201516115876020850182611641565b805160009060808401906115e98582611521565b5060208301516115fc602086018261164a565b50604083015161160f604086018261140a565b506060830151848203606086015261162782826114e9565b95945050505050565b8051604083019061159e84826114e0565b61141381611842565b61141381611870565b60408101611661828561140a565b610d32602083018461164a565b610220810161167d828b61140a565b61168a602083018a61164a565b611697604083018961140a565b6116a4606083018861140a565b6116b1608083018761140a565b6116be60a0830186611563565b6116cc610120830185611563565b6116da6101a0830184611563565b9998505050505050505050565b608081016116f5828761140a565b611702602083018661164a565b81810360408301526117148185611487565b905081810360608301526117288184611419565b9695505050505050565b60208082528101610ba681846114e9565b60208082528101610ba98161152a565b60608101611761828561158d565b610d32604083018461164a565b60208101610ba9828461164a565b60405181810167ffffffffffffffff8111828210171561179b57600080fd5b604052919050565b600067ffffffffffffffff8211156117ba57600080fd5b5060209081020190565b600067ffffffffffffffff8211156117db57600080fd5b506020601f919091017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0160190565b60200190565b5190565b90815260200190565b6000610ba982611857565b151590565b6000610ba98261181d565b80610bd2816118de565b6fffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff1690565b90565b6000610ba982611838565b82818337506000910152565b60005b838110156118a557818101518382015260200161188d565b838111156115875750506000910152565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01690565b600481106118e857fe5b50565b6118f48161181d565b81146118e857600080fd5b6118f481611828565b6118f48161182d565b600381106118e857600080fd5b600481106118e857600080fd5b6118f481611842565b6118f48161187056fea365627a7a72315820e5c4353739728077870f6acae15a247fd7b0bc6b6f65f8fd8eb8e3257ebd96f26c6578706572696d656e74616cf564736f6c63430005100040",
  "sourceMap": "2035:4966:52:-;;132:2:-1;166:7;155:9;146:7;137:37;255:7;249:14;246:1;241:23;235:4;232:33;222:2;;269:9;222:2;293:9;290:1;283:20;323:4;314:7;306:22;347:7;338;331:24",
  "deployedSourceMap": "2035:4966:52:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2158:469;;8:9:-1;5:2;;;30:1;27;20:12;5:2;-1:-1;2158:469:52;;;;;;;;:::i;:::-;;2633:855;;8:9:-1;5:2;;;30:1;27;20:12;5:2;-1:-1;2633:855:52;;;;;;;;:::i;2158:469::-;2401:54;2387:10;:68;;;;;;;;;2383:238;;;2471:27;;;;;2539:19;;2576:20;;;;2471:139;;;;;:50;;;;;;;:139;;2576:20;2471:139;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2471:139:52;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;2471:139:52;;;;2383:238;2158:469;;;:::o;2633:855::-;3042:27;;;;;3099:19;;3132:20;;;;3042:174;;;;;:43;;;;;;;:174;;3132:20;3166:14;;3194:12;;3042:174;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3042:174:52;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;-1:-1;3245:54:52;;-1:-1:-1;3231:68:52;;-1:-1:-1;;3231:68:52;;:10;:68;;;;;;;;;3227:255;;;3315:156;3356:6;3380:13;3411:14;3443;3315:23;:156::i;:::-;2633:855;;;;;;:::o;3494:3505::-;3776:46;;:::i;:::-;3884:37;;:::i;:::-;3924:6;:21;;;:35;;;3977:13;4028:14;4043:1;4028:17;;;;;;;;;;;;;;3924:135;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3924:135:52;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;3924:135:52;;;;;;;101:4:-1;97:9;90:4;84;80:15;76:31;69:5;65:43;126:6;120:4;113:20;0:138;3924:135:52;;;;;;;;;3884:175;;4094:220;;;;;;;;4143:61;4168:6;:35;;;4143:20;:24;;:61;;;;:::i;:::-;4094:220;;;;4230:6;:21;;;:35;;;4266:13;4281:14;4296:1;4281:17;;;;;;;;;;;;;;4230:69;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;4230:69:52;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;4230:69:52;;;;;;;101:4:-1;97:9;90:4;84;80:15;76:31;69:5;65:43;126:6;120:4;113:20;0:138;4230:69:52;;;;;;;;;4094:220;;;4073:241;;3494:3505;4372:47;;:::i;:::-;4481:38;;:::i;:::-;4522:6;:21;;;:35;;;4575:13;4627:14;4666:1;4642:14;:21;:25;4627:41;;;;;;;;;;;;;;4522:160;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;4522:160:52;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;4522:160:52;;;;;;;101:4:-1;97:9;90:4;84;80:15;76:31;69:5;65:43;126:6;120:4;113:20;0:138;4522:160:52;;;;;;;;;4481:201;;4718:246;;;;;;;;4767:63;4793:6;:36;;;4767:21;:25;;:63;;;;:::i;:::-;4718:246;;;;4856:6;:21;;;:35;;;4892:13;4907:14;4946:1;4922:14;:21;:25;4907:41;;;;;;;;;;;;;;4856:93;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;4856:93:52;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;4856:93:52;;;;;;;101:4:-1;97:9;90:4;84;80:15;76:31;69:5;65:43;126:6;120:4;113:20;0:138;4856:93:52;;;;;;;;;4718:246;;;4696:268;;3494:3505;5022:47;;:::i;:::-;5131:38;;:::i;:::-;5172:6;:21;;;:35;;;5225:13;5278:6;:22;;;5301:1;5278:25;;;;;;;;;;;;;;:34;;;5172:154;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;5172:154:52;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;5172:154:52;;;;;;;101:4:-1;97:9;90:4;84;80:15;76:31;69:5;65:43;126:6;120:4;113:20;0:138;5172:154:52;;;;;;;;;5131:195;;5362:299;;;;;;;;5411:65;5437:6;:38;;;5411:21;:25;;:65;;;;:::i;:::-;5362:299;;;;5502:6;:21;;;:35;;;5559:13;5594:6;:22;;;5617:1;5594:25;;;;;;;;;;;;;;:34;;;5502:144;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;5502:144:52;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;5502:144:52;;;;;;;101:4:-1;97:9;90:4;84;80:15;76:31;69:5;65:43;126:6;120:4;113:20;0:138;5502:144:52;;;;;;;;;5362:299;;;5340:321;;3494:3505;5723:6;:22;;;5719:1274;;;5761:6;:27;;;:50;;;5829:13;:19;;;5866:13;:20;;;5924:6;:21;;;:43;;;5968:14;5983:1;5968:17;;;;;;;;;;;;;;5924:62;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;5924:62:52;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;5924:62:52;;;;;;;101:4:-1;97:9;90:4;84;80:15;76:31;69:5;65:43;126:6;120:4;113:20;0:138;5924:62:52;;;;;;;;;6025:6;:21;;;:43;;;6069:14;6108:1;6084:14;:21;:25;6069:41;;;;;;;;;;;;;;6025:86;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6025:86:52;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;6025:86:52;;;;;;;101:4:-1;97:9;90:4;84;80:15;76:31;69:5;65:43;126:6;120:4;113:20;0:138;6025:86:52;;;;;;;;;6151:6;:21;;;:43;;;6195:6;:22;;;6218:1;6195:25;;;;;;;;;;;;;;:34;;;6151:79;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6151:79:52;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;6151:79:52;;;;;;;101:4:-1;97:9;90:4;84;80:15;76:31;69:5;65:43;126:6;120:4;113:20;0:138;6151:79:52;;;;;;;;;6248:18;6284:19;6321;5761:593;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;5761:593:52;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;5761:593:52;;;;5719:1274;;;6385:6;:27;;;:51;;;6454:13;:19;;;6491:13;:20;;;6549:6;:21;;;:43;;;6593:14;6608:1;6593:17;;;;;;;;;;;;;;6549:62;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6549:62:52;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;6549:62:52;;;;;;;101:4:-1;97:9;90:4;84;80:15;76:31;69:5;65:43;126:6;120:4;113:20;0:138;6549:62:52;;;;;;;;;6650:6;:21;;;:43;;;6694:14;6733:1;6709:14;:21;:25;6694:41;;;;;;;;;;;;;;6650:86;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6650:86:52;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;6650:86:52;;;;;;;101:4:-1;97:9;90:4;84;80:15;76:31;69:5;65:43;126:6;120:4;113:20;0:138;6650:86:52;;;;;;;;;6779:6;:21;;;:43;;;6823:6;:22;;;6846:1;6823:25;;;;;;;;;;;;;;:34;;;6779:79;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6779:79:52;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;6779:79:52;;;;;;;101:4:-1;97:9;90:4;84;80:15;76:31;69:5;65:43;126:6;120:4;113:20;0:138;6779:79:52;;;;;;;;;6876:18;6912:19;6949;6385:597;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6385:597:52;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;6385:597:52;;;;3494:3505;;;;;;;:::o;4677:169:104:-;4787:10;;:::i;:::-;4820:19;4824:1;4827:11;4836:1;4827:8;:11::i;:::-;4820:3;:19::i;:::-;4813:26;;4677:169;;;;;:::o;5782:203::-;5875:10;;:::i;:::-;-1:-1:-1;5908:70:104;;;;;;;;;5933:6;;5932:7;5908:70;;;5960:7;;;;5908:70;;;;5782:203;;;;:::o;4852:610::-;4962:10;;:::i;:::-;4988:17;;:::i;:::-;5029:6;;5019;;:16;;;;;;5015:418;;;5065:6;;5051:20;;;;5113:7;;;;;5122;;;;5100:30;;5113:7;5100:12;:30::i;:::-;5085:12;;;:45;5015:418;;;5176:1;:7;;;5165:1;:7;;;:18;5161:262;;5217:6;;5203:20;;;;5269:7;;;;;5278;;;;5256:30;;5269:7;5256:12;:30::i;5161:262::-;5339:6;;5325:20;;;;5391:7;;;;;5400;;;;5378:30;;5391:7;5378:12;:30::i;:::-;5363:12;;;:45;5449:6;4852:610;-1:-1:-1;;;4852:610:104:o;834:176:150:-;892:7;923:5;;;946:6;;;;938:46;;;;;;;;;;;;;;;;;;;;;1274:134;1332:7;1358:43;1362:1;1365;1358:43;;;;;;;;;;;;;;;;;1818:7;1853:12;1845:6;;;;1837:29;;;;;;;;;;;;;;;-1:-1:-1;;1888:5:150;;;1732:187;;;;;;:::o;2035:4966:52:-;;;;;;;;;;;:::i;:::-;;;;;;;:::i;:::-;;;;:::o;:::-;;;;;;;;;;-1:-1:-1;2035:4966:52;;;;;;;;:::o;5:130:-1:-;72:20;;97:33;72:20;97:33;;142:134;220:13;;238:33;220:13;238:33;;336:753;;478:3;471:4;463:6;459:17;455:27;445:2;;496:1;493;486:12;445:2;533:6;520:20;555:105;570:89;652:6;570:89;;;555:105;;;688:21;;;732:4;720:17;;;;546:114;;-1:-1;745:14;;720:17;840:1;825:258;850:6;847:1;844:13;825:258;;;933:3;920:17;912:6;908:30;957:62;1015:3;1003:10;957:62;;;945:75;;-1:-1;1043:4;1034:14;;;;1062;;;;;872:1;865:9;825:258;;;829:14;438:651;;;;;;;;1151:783;;1292:3;1285:4;1277:6;1273:17;1269:27;1259:2;;1310:1;1307;1300:12;1259:2;1347:6;1334:20;1369:104;1384:88;1465:6;1384:88;;1369:104;1360:113;;1490:5;1515:6;1508:5;1501:21;1545:4;1537:6;1533:17;1523:27;;1567:4;1562:3;1558:14;1551:21;;1620:6;1667:3;1659:4;1651:6;1647:17;1642:3;1638:27;1635:36;1632:2;;;1684:1;1681;1674:12;1632:2;1709:1;1694:234;1719:6;1716:1;1713:13;1694:234;;;1777:3;1799:65;1860:3;1848:10;1799:65;;;1787:78;;-1:-1;1888:4;1879:14;;;;1916:4;1907:14;;;;;1741:1;1734:9;1694:234;;1960:707;;2077:3;2070:4;2062:6;2058:17;2054:27;2044:2;;2095:1;2092;2085:12;2044:2;2132:6;2119:20;2154:80;2169:64;2226:6;2169:64;;2154:80;2145:89;;2251:5;2276:6;2269:5;2262:21;2306:4;2298:6;2294:17;2284:27;;2328:4;2323:3;2319:14;2312:21;;2381:6;2428:3;2420:4;2412:6;2408:17;2403:3;2399:27;2396:36;2393:2;;;2445:1;2442;2435:12;2393:2;2470:1;2455:206;2480:6;2477:1;2474:13;2455:206;;;2538:3;2560:37;2593:3;2581:10;2560:37;;;2548:50;;-1:-1;2621:4;2612:14;;;;2640;;;;;2502:1;2495:9;2455:206;;2675:124;2739:20;;2764:30;2739:20;2764:30;;2806:128;2881:13;;2899:30;2881:13;2899:30;;2942:432;;3039:3;3032:4;3024:6;3020:17;3016:27;3006:2;;3057:1;3054;3047:12;3006:2;3094:6;3081:20;3116:60;3131:44;3168:6;3131:44;;3116:60;3107:69;;3196:6;3189:5;3182:21;3232:4;3224:6;3220:17;3265:4;3258:5;3254:16;3300:3;3291:6;3286:3;3282:16;3279:25;3276:2;;;3317:1;3314;3307:12;3276:2;3327:41;3361:6;3356:3;3351;3327:41;;;2999:375;;;;;;;;3382:180;3474:20;;3499:58;3474:20;3499:58;;3766:174;3855:20;;3880:55;3855:20;3880:55;;3947:160;4029:20;;4054:48;4029:20;4054:48;;4175:1763;;4305:6;4293:9;4288:3;4284:19;4280:32;4277:2;;;4325:1;4322;4315:12;4277:2;4343:22;4358:6;4343:22;;;4334:31;-1:-1;4425:1;4457:74;4527:3;4507:9;4457:74;;;4432:100;;-1:-1;4609:2;4642:79;4717:3;4693:22;;;4642:79;;;4635:4;4628:5;4624:16;4617:105;4553:180;4794:2;4827:46;4869:3;4860:6;4849:9;4845:22;4827:46;;;4820:4;4813:5;4809:16;4802:72;4743:142;4949:2;4982:49;5027:3;5018:6;5007:9;5003:22;4982:49;;;4975:4;4968:5;4964:16;4957:75;4895:148;5112:3;5146:49;5191:3;5182:6;5171:9;5167:22;5146:49;;;5139:4;5132:5;5128:16;5121:75;5053:154;5266:3;5300:49;5345:3;5336:6;5325:9;5321:22;5300:49;;;5293:4;5286:5;5282:16;5275:75;5217:144;5435:3;5469:67;5532:3;5523:6;5512:9;5508:22;5469:67;;;5462:4;5455:5;5451:16;5444:93;5371:177;5623:3;5657:67;5720:3;5711:6;5700:9;5696:22;5657:67;;;5650:4;5643:5;5639:16;5632:93;5558:178;5813:3;5849:67;5912:3;5903:6;5892:9;5888:22;5849:67;;;5840:6;5833:5;5829:18;5822:95;5746:182;4271:1667;;;;;5971:468;;6083:4;6071:9;6066:3;6062:19;6058:30;6055:2;;;6101:1;6098;6091:12;6055:2;6119:20;6134:4;6119:20;;;6110:29;-1:-1;6190:1;6222:49;6267:3;6247:9;6222:49;;;6197:75;;-1:-1;6335:2;6368:49;6413:3;6389:22;;;6368:49;;;6361:4;6354:5;6350:16;6343:75;6293:136;6049:390;;;;;6469:495;;6591:4;6579:9;6574:3;6570:19;6566:30;6563:2;;;6609:1;6606;6599:12;6563:2;6627:20;6642:4;6627:20;;;6618:29;-1:-1;6697:1;6729:57;6782:3;6762:9;6729:57;;;6704:83;;-1:-1;6849:2;6882:60;6938:3;6914:22;;;6882:60;;7020:887;;7134:4;7122:9;7117:3;7113:19;7109:30;7106:2;;;7152:1;7149;7142:12;7106:2;7170:20;7185:4;7170:20;;;7161:29;-1:-1;7246:1;7278:64;7338:3;7318:9;7278:64;;;7253:90;;-1:-1;7417:2;7450:49;7495:3;7471:22;;;7450:49;;;7443:4;7436:5;7432:16;7425:75;7364:147;7563:2;7596:49;7641:3;7632:6;7621:9;7617:22;7596:49;;;7589:4;7582:5;7578:16;7571:75;7521:136;7740:2;7729:9;7725:18;7712:32;7764:18;7756:6;7753:30;7750:2;;;7796:1;7793;7786:12;7750:2;7831:54;7881:3;7872:6;7861:9;7857:22;7831:54;;;7824:4;7817:5;7813:16;7806:80;7667:230;7100:807;;;;;7964:479;;8081:4;8069:9;8064:3;8060:19;8056:30;8053:2;;;8099:1;8096;8089:12;8053:2;8117:20;8132:4;8117:20;;;8108:29;-1:-1;8191:1;8223:49;8268:3;8248:9;8223:49;;8509:797;;8639:4;8627:9;8622:3;8618:19;8614:30;8611:2;;;8657:1;8654;8647:12;8611:2;8675:20;8690:4;8675:20;;;8666:29;-1:-1;8758:1;8790:49;8835:3;8815:9;8790:49;;;8765:75;;-1:-1;8912:2;8945:49;8990:3;8966:22;;;8945:49;;;8938:4;8931:5;8927:16;8920:75;8861:145;9095:2;9084:9;9080:18;9067:32;9119:18;9111:6;9108:30;9105:2;;;9151:1;9148;9141:12;9105:2;9186:98;9280:3;9271:6;9260:9;9256:22;9186:98;;;9179:4;9172:5;9168:16;9161:124;9016:280;8605:701;;;;;9336:458;;9443:4;9431:9;9426:3;9422:19;9418:30;9415:2;;;9461:1;9458;9451:12;9415:2;9479:20;9494:4;9479:20;;;9470:29;-1:-1;9549:1;9581:46;9623:3;9603:9;9581:46;;9824:495;;9946:4;9934:9;9929:3;9925:19;9921:30;9918:2;;;9964:1;9961;9954:12;9918:2;9982:20;9997:4;9982:20;;;9973:29;-1:-1;10052:1;10084:57;10137:3;10117:9;10084:57;;;10059:83;;-1:-1;10204:2;10237:60;10293:3;10269:22;;;10237:60;;10326:134;10404:13;;10422:33;10404:13;10422:33;;10467:130;10534:20;;10559:33;10534:20;10559:33;;10604:134;10682:13;;10700:33;10682:13;10700:33;;10745:263;;10860:2;10848:9;10839:7;10835:23;10831:32;10828:2;;;10876:1;10873;10866:12;10828:2;10911:1;10928:64;10984:7;10964:9;10928:64;;;10918:74;10822:186;-1:-1;;;;10822:186;11015:1534;;;;;;;11406:3;11394:9;11385:7;11381:23;11377:33;11374:2;;;11423:1;11420;11413:12;11374:2;11458:1;11475:94;11561:7;11541:9;11475:94;;;11465:104;;11437:138;11606:3;11625:76;11693:7;11684:6;11673:9;11669:22;11625:76;;;11615:86;;11585:122;11766:3;11755:9;11751:19;11738:33;11791:18;11783:6;11780:30;11777:2;;;11823:1;11820;11813:12;11777:2;11843:78;11913:7;11904:6;11893:9;11889:22;11843:78;;;11833:88;;11717:210;11986:3;11975:9;11971:19;11958:33;12011:18;12003:6;12000:30;11997:2;;;12043:1;12040;12033:12;11997:2;12063:103;12158:7;12149:6;12138:9;12134:22;12063:103;;;12053:113;;11937:235;12231:3;12220:9;12216:19;12203:33;12256:18;12248:6;12245:30;12242:2;;;12288:1;12285;12278:12;12242:2;12308:94;12394:7;12385:6;12374:9;12370:22;12308:94;;;12298:104;;12182:226;12439:3;12458:75;12525:7;12516:6;12505:9;12501:22;12458:75;;;12448:85;;12418:121;11368:1181;;;;;;;;;12556:666;;;;12780:3;12768:9;12759:7;12755:23;12751:33;12748:2;;;12797:1;12794;12787:12;12748:2;12832:1;12849:94;12935:7;12915:9;12849:94;;;12839:104;;12811:138;12980:3;12999:76;13067:7;13058:6;13047:9;13043:22;12999:76;;;12989:86;;12959:122;13112:3;13131:75;13198:7;13189:6;13178:9;13174:22;13131:75;;;13121:85;;13091:121;12742:480;;;;;;13229:307;;13366:2;13354:9;13345:7;13341:23;13337:32;13334:2;;;13382:1;13379;13372:12;13334:2;13417:1;13434:86;13512:7;13492:9;13434:86;;13543:307;;13680:2;13668:9;13659:7;13655:23;13651:32;13648:2;;;13696:1;13693;13686:12;13648:2;13731:1;13748:86;13826:7;13806:9;13748:86;;13858:257;;14009:100;14105:3;14097:6;14009:100;;14124:173;;14211:46;14253:3;14245:6;14211:46;;;-1:-1;;14286:4;14277:14;;14204:93;14305:103;14378:24;14396:5;14378:24;;;14373:3;14366:37;14360:48;;;14636:1048;;14831:79;14904:5;14831:79;;;14923:111;15027:6;15022:3;14923:111;;;14916:118;;15057:3;15099:4;15091:6;15087:17;15082:3;15078:27;15126:81;15201:5;15126:81;;;15227:7;15255:1;15240:405;15265:6;15262:1;15259:13;15240:405;;;15327:9;15321:4;15317:20;15312:3;15305:33;15372:6;15366:13;15394:114;15503:4;15488:13;15394:114;;;15386:122;;15525:85;15603:6;15525:85;;;15633:4;15624:14;;;;;15515:95;-1:-1;;15287:1;15280:9;15240:405;;;-1:-1;15658:4;;14810:874;-1:-1;;;;;;;14810:874;15723:690;;15868:54;15916:5;15868:54;;;15935:86;16014:6;16009:3;15935:86;;;15928:93;;16042:56;16092:5;16042:56;;;16118:7;16146:1;16131:260;16156:6;16153:1;16150:13;16131:260;;;16223:6;16217:13;16244:63;16303:3;16288:13;16244:63;;;16237:70;;16324:60;16377:6;16324:60;;;16314:70;-1:-1;;16178:1;16171:9;16131:260;;;-1:-1;16404:3;;15847:566;-1:-1;;;;;15847:566;16421:94;16488:21;16503:5;16488:21;;16522:315;;16618:34;16646:5;16618:34;;;16664:60;16717:6;16712:3;16664:60;;;16657:67;;16729:52;16774:6;16769:3;16762:4;16755:5;16751:16;16729:52;;;16802:29;16824:6;16802:29;;;16793:39;;;;16598:239;-1:-1;;;16598:239;16844:142;16930:50;16974:5;16930:50;;17348:327;;17508:67;17572:2;17567:3;17508:67;;;17608:29;17588:50;;17666:2;17657:12;;17494:181;-1:-1;;17494:181;17748:576;17975:23;;17905:4;17896:14;;;18004:103;17900:3;17975:23;18004:103;;;17925:188;18188:4;18181:5;18177:16;18171:23;18200:103;18297:4;18292:3;18288:14;18274:12;18200:103;;;18123:186;17878:446;;;;18380:475;18586:23;;18519:4;18510:14;;;18615:63;18514:3;18586:23;18615:63;;;18539:145;18759:4;18752:5;18748:16;18742:23;18771:63;18828:4;18823:3;18819:14;18805:12;18771:63;;18905:451;19094:23;;19028:4;19019:14;;;19123:57;19023:3;19094:23;19123:57;;;19048:138;19260:4;19253:5;19249:16;19243:23;19272:63;19329:4;19324:3;19320:14;19306:12;19272:63;;19458:906;19675:23;;19458:906;;19603:4;19594:14;;;19704:76;19598:3;19675:23;19704:76;;;19623:163;19872:4;19865:5;19861:16;19855:23;19884:63;19941:4;19936:3;19932:14;19918:12;19884:63;;;19796:157;20028:4;20021:5;20017:16;20011:23;20040:63;20097:4;20092:3;20088:14;20074:12;20040:63;;;19963:146;20187:4;20180:5;20176:16;20170:23;20239:3;20233:4;20229:14;20222:4;20217:3;20213:14;20206:38;20259:67;20321:4;20307:12;20259:67;;;20251:75;19576:788;-1:-1;;;;;19576:788;20414:451;20603:23;;20537:4;20528:14;;;20632:57;20532:3;20603:23;20632:57;;20872:103;20945:24;20963:5;20945:24;;20982:103;21055:24;21073:5;21055:24;;21212:324;21358:2;21343:18;;21372:71;21347:9;21416:6;21372:71;;;21454:72;21522:2;21511:9;21507:18;21498:6;21454:72;;21543:1379;22049:3;22034:19;;22064:71;22038:9;22108:6;22064:71;;;22146:72;22214:2;22203:9;22199:18;22190:6;22146:72;;;22229;22297:2;22286:9;22282:18;22273:6;22229:72;;;22312;22380:2;22369:9;22365:18;22356:6;22312:72;;;22395:73;22463:3;22452:9;22448:19;22439:6;22395:73;;;22479:137;22611:3;22600:9;22596:19;22587:6;22479:137;;;22627;22759:3;22748:9;22744:19;22735:6;22627:137;;;22775;22907:3;22896:9;22892:19;22883:6;22775:137;;;22020:902;;;;;;;;;;;;22929:943;23281:3;23266:19;;23296:71;23270:9;23340:6;23296:71;;;23378:72;23446:2;23435:9;23431:18;23422:6;23378:72;;;23498:9;23492:4;23488:20;23483:2;23472:9;23468:18;23461:48;23523:108;23626:4;23617:6;23523:108;;;23515:116;;23679:9;23673:4;23669:20;23664:2;23653:9;23649:18;23642:48;23704:158;23857:4;23848:6;23704:158;;;23696:166;23252:620;-1:-1;;;;;;23252:620;23879:301;24017:2;24031:47;;;24002:18;;24092:78;24002:18;24156:6;24092:78;;24187:407;24378:2;24392:47;;;24363:18;;24453:131;24363:18;24453:131;;24601:416;24793:2;24778:18;;24807:117;24782:9;24897:6;24807:117;;;24935:72;25003:2;24992:9;24988:18;24979:6;24935:72;;25024:213;25142:2;25127:18;;25156:71;25131:9;25200:6;25156:71;;25244:256;25306:2;25300:9;25332:17;;;25407:18;25392:34;;25428:22;;;25389:62;25386:2;;;25464:1;25461;25454:12;25386:2;25480;25473:22;25284:216;;-1:-1;25284:216;25507:329;;25691:18;25683:6;25680:30;25677:2;;;25723:1;25720;25713:12;25677:2;-1:-1;25758:4;25746:17;;;25811:15;;25614:222;26489:317;;26628:18;26620:6;26617:30;26614:2;;;26660:1;26657;26650:12;26614:2;-1:-1;26791:4;26727;26704:17;;;;26723:9;26700:33;26781:15;;26551:255;26813:176;26962:4;26953:14;;26910:79;27154:162;27282:12;;27253:63;27976:203;28119:19;;;28168:4;28159:14;;28112:67;28707:91;;28769:24;28787:5;28769:24;;28805:85;28871:13;28864:21;;28847:43;28897:116;;28984:24;29002:5;28984:24;;29148:136;29225:5;29231:48;29225:5;29231:48;;29291:113;29364:34;29353:46;;29336:68;29411:121;29484:42;29473:54;;29456:76;29539:72;29601:5;29584:27;29618:136;;29710:39;29743:5;29710:39;;29762:145;29843:6;29838:3;29833;29820:30;-1:-1;29899:1;29881:16;;29874:27;29813:94;29916:268;29981:1;29988:101;30002:6;29999:1;29996:13;29988:101;;;30069:11;;;30063:18;30050:11;;;30043:39;30024:2;30017:10;29988:101;;;30104:6;30101:1;30098:13;30095:2;;;-1:-1;;30169:1;30151:16;;30144:27;29965:219;30192:97;30280:2;30260:14;30276:7;30256:28;;30240:49;30297:106;30381:1;30374:5;30371:12;30361:2;;30387:9;30361:2;30355:48;;30410:117;30479:24;30497:5;30479:24;;;30472:5;30469:35;30459:2;;30518:1;30515;30508:12;30534:111;30600:21;30615:5;30600:21;;30652:167;30746:49;30789:5;30746:49;;31010:116;31101:1;31094:5;31091:12;31081:2;;31117:1;31114;31107:12;31133:109;31217:1;31210:5;31207:12;31197:2;;31233:1;31230;31223:12;31249:117;31318:24;31336:5;31318:24;;31373:117;31442:24;31460:5;31442:24;",
  "source": "/*\n\n    Copyright 2023 Dolomite.\n\n    Licensed under the Apache License, Version 2.0 (the \"License\");\n    you may not use this file except in compliance with the License.\n    You may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\n    Unless required by applicable law or agreed to in writing, software\n    distributed under the License is distributed on an \"AS IS\" BASIS,\n    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n    See the License for the specific language governing permissions and\n    limitations under the License.\n\n*/\n\npragma solidity ^0.5.7;\npragma experimental ABIEncoderV2;\n\nimport { ReentrancyGuard } from \"@openzeppelin/contracts/utils/ReentrancyGuard.sol\";\n\nimport { IDolomiteMargin } from \"../../protocol/interfaces/IDolomiteMargin.sol\";\n\nimport { Account } from \"../../protocol/lib/Account.sol\";\nimport { Actions } from \"../../protocol/lib/Actions.sol\";\nimport { Events } from \"../../protocol/lib/Events.sol\";\nimport { Require } from \"../../protocol/lib/Require.sol\";\nimport { Types } from \"../../protocol/lib/Types.sol\";\n\nimport { HasLiquidatorRegistry } from \"../helpers/HasLiquidatorRegistry.sol\";\nimport { OnlyDolomiteMargin } from \"../helpers/OnlyDolomiteMargin.sol\";\n\nimport { IExpiry } from \"../interfaces/IExpiry.sol\";\nimport { IGenericTraderProxyBase } from \"../interfaces/IGenericTraderProxyBase.sol\";\nimport { IGenericTraderProxyV1 } from \"../interfaces/IGenericTraderProxyV1.sol\";\nimport { IIsolationModeUnwrapperTrader } from \"../interfaces/IIsolationModeUnwrapperTrader.sol\";\nimport { IIsolationModeWrapperTrader } from \"../interfaces/IIsolationModeWrapperTrader.sol\";\nimport { IEventEmitterRegistry } from \"../interfaces/IEventEmitterRegistry.sol\";\n\nimport { AccountActionLib } from \"../lib/AccountActionLib.sol\";\nimport { AccountBalanceLib } from \"../lib/AccountBalanceLib.sol\";\n\n\n\n/**\n * @title   GenericTraderProxyV1Lib\n * @author  Dolomite\n *\n * @dev Library contract for reducing code size of the GenericTraderProxyV1 contract\n */\nlibrary GenericTraderProxyV1Lib {\n    using Types for Types.Wei;\n\n    // ============ Internal Functions ============\n\n    function logBeforeZapEvents(\n        IGenericTraderProxyBase.GenericTraderProxyCache memory _cache,\n        Account.Info memory _tradeAccount,\n        IGenericTraderProxyV1.EventEmissionType _eventType\n    ) public {\n        if (_eventType == IGenericTraderProxyV1.EventEmissionType.BorrowPosition) {\n            _cache.eventEmitterRegistry.emitBorrowPositionOpen(\n                _tradeAccount.owner,\n                _tradeAccount.number\n            );\n        }\n    }\n\n    function logAfterZapEvents(\n        IGenericTraderProxyBase.GenericTraderProxyCache memory _cache,\n        Account.Info memory _tradeAccount,\n        uint256[] memory _marketIdsPath,\n        IGenericTraderProxyBase.TraderParam[] memory _tradersPath,\n        IGenericTraderProxyV1.TransferCollateralParam memory _transferParam,\n        IGenericTraderProxyV1.EventEmissionType _eventType\n    ) public {\n        _cache.eventEmitterRegistry.emitZapExecuted(\n            _tradeAccount.owner,\n            _tradeAccount.number,\n            _marketIdsPath,\n            _tradersPath\n        );\n\n        if (_eventType == IGenericTraderProxyV1.EventEmissionType.MarginPosition) {\n            _logMarginPositionEvent(\n                _cache,\n                _tradeAccount,\n                _marketIdsPath,\n                _transferParam\n            );\n        }\n    }\n\n    function _logMarginPositionEvent(\n        IGenericTraderProxyBase.GenericTraderProxyCache memory _cache,\n        Account.Info memory _tradeAccount,\n        uint256[] memory _marketIdsPath,\n        IGenericTraderProxyV1.TransferCollateralParam memory _param\n    ) internal {\n        Events.BalanceUpdate memory inputBalanceUpdate;\n        // solium-disable indentation\n        {\n            Types.Wei memory inputBalanceWeiAfter = _cache.dolomiteMargin.getAccountWei(\n                _tradeAccount,\n                /* _inputToken = */ _marketIdsPath[0]\n            );\n            inputBalanceUpdate = Events.BalanceUpdate({\n                deltaWei: inputBalanceWeiAfter.sub(_cache.inputBalanceWeiBeforeOperate),\n                newPar: _cache.dolomiteMargin.getAccountPar(_tradeAccount, _marketIdsPath[0])\n            });\n        }\n        // solium-enable indentation\n\n        Events.BalanceUpdate memory outputBalanceUpdate;\n        // solium-disable indentation\n        {\n            Types.Wei memory outputBalanceWeiAfter = _cache.dolomiteMargin.getAccountWei(\n                _tradeAccount,\n                /* _outputToken = */ _marketIdsPath[_marketIdsPath.length - 1]\n            );\n            outputBalanceUpdate = Events.BalanceUpdate({\n                deltaWei: outputBalanceWeiAfter.sub(_cache.outputBalanceWeiBeforeOperate),\n                newPar: _cache.dolomiteMargin.getAccountPar(_tradeAccount, _marketIdsPath[_marketIdsPath.length - 1])\n            });\n        }\n        // solium-enable indentation\n\n        Events.BalanceUpdate memory marginBalanceUpdate;\n        // solium-disable indentation\n        {\n            Types.Wei memory marginBalanceWeiAfter = _cache.dolomiteMargin.getAccountWei(\n                _tradeAccount,\n                /* _transferToken = */_param.transferAmounts[0].marketId\n            );\n            marginBalanceUpdate = Events.BalanceUpdate({\n                deltaWei: marginBalanceWeiAfter.sub(_cache.transferBalanceWeiBeforeOperate),\n                newPar: _cache.dolomiteMargin.getAccountPar(\n                    _tradeAccount,\n                    _param.transferAmounts[0].marketId\n                )\n            });\n        }\n        // solium-enable indentation\n\n        if (_cache.isMarginDeposit) {\n            _cache.eventEmitterRegistry.emitMarginPositionOpen(\n                _tradeAccount.owner,\n                _tradeAccount.number,\n                /* _inputToken = */ _cache.dolomiteMargin.getMarketTokenAddress(_marketIdsPath[0]),\n                /* _outputToken = */ _cache.dolomiteMargin.getMarketTokenAddress(_marketIdsPath[_marketIdsPath.length - 1]),\n                /* _depositToken = */ _cache.dolomiteMargin.getMarketTokenAddress(_param.transferAmounts[0].marketId),\n                inputBalanceUpdate,\n                outputBalanceUpdate,\n                marginBalanceUpdate\n            );\n        } else {\n            _cache.eventEmitterRegistry.emitMarginPositionClose(\n                _tradeAccount.owner,\n                _tradeAccount.number,\n                /* _inputToken = */ _cache.dolomiteMargin.getMarketTokenAddress(_marketIdsPath[0]),\n                /* _outputToken = */ _cache.dolomiteMargin.getMarketTokenAddress(_marketIdsPath[_marketIdsPath.length - 1]),\n                /* _withdrawalToken = */ _cache.dolomiteMargin.getMarketTokenAddress(_param.transferAmounts[0].marketId),\n                inputBalanceUpdate,\n                outputBalanceUpdate,\n                marginBalanceUpdate\n            );\n        }\n    }\n}\n",
  "sourcePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/proxies/GenericTraderProxyV1Lib.sol",
  "ast": {
    "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/proxies/GenericTraderProxyV1Lib.sol",
    "exportedSymbols": {
      "GenericTraderProxyV1Lib": [
        11828
      ]
    },
    "id": 11829,
    "nodeType": "SourceUnit",
    "nodes": [
      {
        "id": 11494,
        "literals": [
          "solidity",
          "^",
          "0.5",
          ".7"
        ],
        "nodeType": "PragmaDirective",
        "src": "595:23:52"
      },
      {
        "id": 11495,
        "literals": [
          "experimental",
          "ABIEncoderV2"
        ],
        "nodeType": "PragmaDirective",
        "src": "619:33:52"
      },
      {
        "absolutePath": "@openzeppelin/contracts/utils/ReentrancyGuard.sol",
        "file": "@openzeppelin/contracts/utils/ReentrancyGuard.sol",
        "id": 11497,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 38093,
        "src": "654:84:52",
        "symbolAliases": [
          {
            "foreign": 11496,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/interfaces/IDolomiteMargin.sol",
        "file": "../../protocol/interfaces/IDolomiteMargin.sol",
        "id": 11499,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 24694,
        "src": "740:80:52",
        "symbolAliases": [
          {
            "foreign": 11498,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/lib/Account.sol",
        "file": "../../protocol/lib/Account.sol",
        "id": 11501,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 24886,
        "src": "822:57:52",
        "symbolAliases": [
          {
            "foreign": 11500,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/lib/Actions.sol",
        "file": "../../protocol/lib/Actions.sol",
        "id": 11503,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 25370,
        "src": "880:57:52",
        "symbolAliases": [
          {
            "foreign": 11502,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/lib/Events.sol",
        "file": "../../protocol/lib/Events.sol",
        "id": 11505,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 27154,
        "src": "938:55:52",
        "symbolAliases": [
          {
            "foreign": 11504,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/lib/Require.sol",
        "file": "../../protocol/lib/Require.sol",
        "id": 11507,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 28453,
        "src": "994:57:52",
        "symbolAliases": [
          {
            "foreign": 11506,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/lib/Types.sol",
        "file": "../../protocol/lib/Types.sol",
        "id": 11509,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 31362,
        "src": "1052:53:52",
        "symbolAliases": [
          {
            "foreign": 11508,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/helpers/HasLiquidatorRegistry.sol",
        "file": "../helpers/HasLiquidatorRegistry.sol",
        "id": 11511,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 1723,
        "src": "1107:77:52",
        "symbolAliases": [
          {
            "foreign": 11510,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/helpers/OnlyDolomiteMargin.sol",
        "file": "../helpers/OnlyDolomiteMargin.sol",
        "id": 11513,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 3067,
        "src": "1185:71:52",
        "symbolAliases": [
          {
            "foreign": 11512,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/interfaces/IExpiry.sol",
        "file": "../interfaces/IExpiry.sol",
        "id": 11515,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 4566,
        "src": "1258:52:52",
        "symbolAliases": [
          {
            "foreign": 11514,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/interfaces/IGenericTraderProxyBase.sol",
        "file": "../interfaces/IGenericTraderProxyBase.sol",
        "id": 11517,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 4609,
        "src": "1311:84:52",
        "symbolAliases": [
          {
            "foreign": 11516,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/interfaces/IGenericTraderProxyV1.sol",
        "file": "../interfaces/IGenericTraderProxyV1.sol",
        "id": 11519,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 4698,
        "src": "1396:80:52",
        "symbolAliases": [
          {
            "foreign": 11518,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/interfaces/IIsolationModeUnwrapperTrader.sol",
        "file": "../interfaces/IIsolationModeUnwrapperTrader.sol",
        "id": 11521,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 4771,
        "src": "1477:96:52",
        "symbolAliases": [
          {
            "foreign": 11520,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/interfaces/IIsolationModeWrapperTrader.sol",
        "file": "../interfaces/IIsolationModeWrapperTrader.sol",
        "id": 11523,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 4829,
        "src": "1574:92:52",
        "symbolAliases": [
          {
            "foreign": 11522,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/interfaces/IEventEmitterRegistry.sol",
        "file": "../interfaces/IEventEmitterRegistry.sol",
        "id": 11525,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 4499,
        "src": "1667:80:52",
        "symbolAliases": [
          {
            "foreign": 11524,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/lib/AccountActionLib.sol",
        "file": "../lib/AccountActionLib.sol",
        "id": 11527,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 5820,
        "src": "1749:63:52",
        "symbolAliases": [
          {
            "foreign": 11526,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/lib/AccountBalanceLib.sol",
        "file": "../lib/AccountBalanceLib.sol",
        "id": 11529,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 5892,
        "src": "1813:65:52",
        "symbolAliases": [
          {
            "foreign": 11528,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "baseContracts": [],
        "contractDependencies": [],
        "contractKind": "library",
        "documentation": "@title   GenericTraderProxyV1Lib\n@author  Dolomite\n * @dev Library contract for reducing code size of the GenericTraderProxyV1 contract",
        "fullyImplemented": true,
        "id": 11828,
        "linearizedBaseContracts": [
          11828
        ],
        "name": "GenericTraderProxyV1Lib",
        "nodeType": "ContractDefinition",
        "nodes": [
          {
            "id": 11532,
            "libraryName": {
              "contractScope": null,
              "id": 11530,
              "name": "Types",
              "nodeType": "UserDefinedTypeName",
              "referencedDeclaration": 31361,
              "src": "2079:5:52",
              "typeDescriptions": {
                "typeIdentifier": "t_contract$_Types_$31361",
                "typeString": "library Types"
              }
            },
            "nodeType": "UsingForDirective",
            "src": "2073:26:52",
            "typeName": {
              "contractScope": null,
              "id": 11531,
              "name": "Types.Wei",
              "nodeType": "UserDefinedTypeName",
              "referencedDeclaration": 31149,
              "src": "2089:9:52",
              "typeDescriptions": {
                "typeIdentifier": "t_struct$_Wei_$31149_storage_ptr",
                "typeString": "struct Types.Wei"
              }
            }
          },
          {
            "body": {
              "id": 11559,
              "nodeType": "Block",
              "src": "2373:254:52",
              "statements": [
                {
                  "condition": {
                    "argumentTypes": null,
                    "commonType": {
                      "typeIdentifier": "t_enum$_EventEmissionType_$4627",
                      "typeString": "enum IGenericTraderProxyV1.EventEmissionType"
                    },
                    "id": 11545,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftExpression": {
                      "argumentTypes": null,
                      "id": 11541,
                      "name": "_eventType",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 11538,
                      "src": "2387:10:52",
                      "typeDescriptions": {
                        "typeIdentifier": "t_enum$_EventEmissionType_$4627",
                        "typeString": "enum IGenericTraderProxyV1.EventEmissionType"
                      }
                    },
                    "nodeType": "BinaryOperation",
                    "operator": "==",
                    "rightExpression": {
                      "argumentTypes": null,
                      "expression": {
                        "argumentTypes": null,
                        "expression": {
                          "argumentTypes": null,
                          "id": 11542,
                          "name": "IGenericTraderProxyV1",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 4697,
                          "src": "2401:21:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_type$_t_contract$_IGenericTraderProxyV1_$4697_$",
                            "typeString": "type(contract IGenericTraderProxyV1)"
                          }
                        },
                        "id": 11543,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "EventEmissionType",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": 4627,
                        "src": "2401:39:52",
                        "typeDescriptions": {
                          "typeIdentifier": "t_type$_t_enum$_EventEmissionType_$4627_$",
                          "typeString": "type(enum IGenericTraderProxyV1.EventEmissionType)"
                        }
                      },
                      "id": 11544,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": true,
                      "lValueRequested": false,
                      "memberName": "BorrowPosition",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": null,
                      "src": "2401:54:52",
                      "typeDescriptions": {
                        "typeIdentifier": "t_enum$_EventEmissionType_$4627",
                        "typeString": "enum IGenericTraderProxyV1.EventEmissionType"
                      }
                    },
                    "src": "2387:68:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "falseBody": null,
                  "id": 11558,
                  "nodeType": "IfStatement",
                  "src": "2383:238:52",
                  "trueBody": {
                    "id": 11557,
                    "nodeType": "Block",
                    "src": "2457:164:52",
                    "statements": [
                      {
                        "expression": {
                          "argumentTypes": null,
                          "arguments": [
                            {
                              "argumentTypes": null,
                              "expression": {
                                "argumentTypes": null,
                                "id": 11551,
                                "name": "_tradeAccount",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 11536,
                                "src": "2539:13:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                                  "typeString": "struct Account.Info memory"
                                }
                              },
                              "id": 11552,
                              "isConstant": false,
                              "isLValue": true,
                              "isPure": false,
                              "lValueRequested": false,
                              "memberName": "owner",
                              "nodeType": "MemberAccess",
                              "referencedDeclaration": 24848,
                              "src": "2539:19:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "expression": {
                                "argumentTypes": null,
                                "id": 11553,
                                "name": "_tradeAccount",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 11536,
                                "src": "2576:13:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                                  "typeString": "struct Account.Info memory"
                                }
                              },
                              "id": 11554,
                              "isConstant": false,
                              "isLValue": true,
                              "isPure": false,
                              "lValueRequested": false,
                              "memberName": "number",
                              "nodeType": "MemberAccess",
                              "referencedDeclaration": 24850,
                              "src": "2576:20:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              }
                            }
                          ],
                          "expression": {
                            "argumentTypes": [
                              {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              },
                              {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              }
                            ],
                            "expression": {
                              "argumentTypes": null,
                              "expression": {
                                "argumentTypes": null,
                                "id": 11546,
                                "name": "_cache",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 11534,
                                "src": "2471:6:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                  "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                                }
                              },
                              "id": 11549,
                              "isConstant": false,
                              "isLValue": true,
                              "isPure": false,
                              "lValueRequested": false,
                              "memberName": "eventEmitterRegistry",
                              "nodeType": "MemberAccess",
                              "referencedDeclaration": 4592,
                              "src": "2471:27:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_contract$_IEventEmitterRegistry_$4498",
                                "typeString": "contract IEventEmitterRegistry"
                              }
                            },
                            "id": 11550,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": false,
                            "lValueRequested": false,
                            "memberName": "emitBorrowPositionOpen",
                            "nodeType": "MemberAccess",
                            "referencedDeclaration": 4459,
                            "src": "2471:50:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$",
                              "typeString": "function (address,uint256) external"
                            }
                          },
                          "id": 11555,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "kind": "functionCall",
                          "lValueRequested": false,
                          "names": [],
                          "nodeType": "FunctionCall",
                          "src": "2471:139:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_tuple$__$",
                            "typeString": "tuple()"
                          }
                        },
                        "id": 11556,
                        "nodeType": "ExpressionStatement",
                        "src": "2471:139:52"
                      }
                    ]
                  }
                }
              ]
            },
            "documentation": null,
            "id": 11560,
            "implemented": true,
            "kind": "function",
            "modifiers": [],
            "name": "logBeforeZapEvents",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 11539,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 11534,
                  "name": "_cache",
                  "nodeType": "VariableDeclaration",
                  "scope": 11560,
                  "src": "2195:61:52",
                  "stateVariable": false,
                  "storageLocation": "memory",
                  "typeDescriptions": {
                    "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                    "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache"
                  },
                  "typeName": {
                    "contractScope": null,
                    "id": 11533,
                    "name": "IGenericTraderProxyBase.GenericTraderProxyCache",
                    "nodeType": "UserDefinedTypeName",
                    "referencedDeclaration": 4607,
                    "src": "2195:47:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_storage_ptr",
                      "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 11536,
                  "name": "_tradeAccount",
                  "nodeType": "VariableDeclaration",
                  "scope": 11560,
                  "src": "2266:33:52",
                  "stateVariable": false,
                  "storageLocation": "memory",
                  "typeDescriptions": {
                    "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                    "typeString": "struct Account.Info"
                  },
                  "typeName": {
                    "contractScope": null,
                    "id": 11535,
                    "name": "Account.Info",
                    "nodeType": "UserDefinedTypeName",
                    "referencedDeclaration": 24851,
                    "src": "2266:12:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_struct$_Info_$24851_storage_ptr",
                      "typeString": "struct Account.Info"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 11538,
                  "name": "_eventType",
                  "nodeType": "VariableDeclaration",
                  "scope": 11560,
                  "src": "2309:50:52",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_enum$_EventEmissionType_$4627",
                    "typeString": "enum IGenericTraderProxyV1.EventEmissionType"
                  },
                  "typeName": {
                    "contractScope": null,
                    "id": 11537,
                    "name": "IGenericTraderProxyV1.EventEmissionType",
                    "nodeType": "UserDefinedTypeName",
                    "referencedDeclaration": 4627,
                    "src": "2309:39:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_enum$_EventEmissionType_$4627",
                      "typeString": "enum IGenericTraderProxyV1.EventEmissionType"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "2185:180:52"
            },
            "returnParameters": {
              "id": 11540,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "2373:0:52"
            },
            "scope": 11828,
            "src": "2158:469:52",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "public"
          },
          {
            "body": {
              "id": 11604,
              "nodeType": "Block",
              "src": "3032:456:52",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "expression": {
                          "argumentTypes": null,
                          "id": 11582,
                          "name": "_tradeAccount",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 11564,
                          "src": "3099:13:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                            "typeString": "struct Account.Info memory"
                          }
                        },
                        "id": 11583,
                        "isConstant": false,
                        "isLValue": true,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "owner",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": 24848,
                        "src": "3099:19:52",
                        "typeDescriptions": {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "expression": {
                          "argumentTypes": null,
                          "id": 11584,
                          "name": "_tradeAccount",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 11564,
                          "src": "3132:13:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                            "typeString": "struct Account.Info memory"
                          }
                        },
                        "id": 11585,
                        "isConstant": false,
                        "isLValue": true,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "number",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": 24850,
                        "src": "3132:20:52",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 11586,
                        "name": "_marketIdsPath",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 11567,
                        "src": "3166:14:52",
                        "typeDescriptions": {
                          "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                          "typeString": "uint256[] memory"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 11587,
                        "name": "_tradersPath",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 11570,
                        "src": "3194:12:52",
                        "typeDescriptions": {
                          "typeIdentifier": "t_array$_t_struct$_TraderParam_$4588_memory_$dyn_memory_ptr",
                          "typeString": "struct IGenericTraderProxyBase.TraderParam memory[] memory"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        },
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        },
                        {
                          "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                          "typeString": "uint256[] memory"
                        },
                        {
                          "typeIdentifier": "t_array$_t_struct$_TraderParam_$4588_memory_$dyn_memory_ptr",
                          "typeString": "struct IGenericTraderProxyBase.TraderParam memory[] memory"
                        }
                      ],
                      "expression": {
                        "argumentTypes": null,
                        "expression": {
                          "argumentTypes": null,
                          "id": 11577,
                          "name": "_cache",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 11562,
                          "src": "3042:6:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                            "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                          }
                        },
                        "id": 11580,
                        "isConstant": false,
                        "isLValue": true,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "eventEmitterRegistry",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": 4592,
                        "src": "3042:27:52",
                        "typeDescriptions": {
                          "typeIdentifier": "t_contract$_IEventEmitterRegistry_$4498",
                          "typeString": "contract IEventEmitterRegistry"
                        }
                      },
                      "id": 11581,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "emitZapExecuted",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 4452,
                      "src": "3042:43:52",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$_t_array$_t_uint256_$dyn_memory_ptr_$_t_array$_t_struct$_TraderParam_$4588_memory_$dyn_memory_ptr_$returns$__$",
                        "typeString": "function (address,uint256,uint256[] memory,struct IGenericTraderProxyBase.TraderParam memory[] memory) external"
                      }
                    },
                    "id": 11588,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "3042:174:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 11589,
                  "nodeType": "ExpressionStatement",
                  "src": "3042:174:52"
                },
                {
                  "condition": {
                    "argumentTypes": null,
                    "commonType": {
                      "typeIdentifier": "t_enum$_EventEmissionType_$4627",
                      "typeString": "enum IGenericTraderProxyV1.EventEmissionType"
                    },
                    "id": 11594,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftExpression": {
                      "argumentTypes": null,
                      "id": 11590,
                      "name": "_eventType",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 11574,
                      "src": "3231:10:52",
                      "typeDescriptions": {
                        "typeIdentifier": "t_enum$_EventEmissionType_$4627",
                        "typeString": "enum IGenericTraderProxyV1.EventEmissionType"
                      }
                    },
                    "nodeType": "BinaryOperation",
                    "operator": "==",
                    "rightExpression": {
                      "argumentTypes": null,
                      "expression": {
                        "argumentTypes": null,
                        "expression": {
                          "argumentTypes": null,
                          "id": 11591,
                          "name": "IGenericTraderProxyV1",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 4697,
                          "src": "3245:21:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_type$_t_contract$_IGenericTraderProxyV1_$4697_$",
                            "typeString": "type(contract IGenericTraderProxyV1)"
                          }
                        },
                        "id": 11592,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "EventEmissionType",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": 4627,
                        "src": "3245:39:52",
                        "typeDescriptions": {
                          "typeIdentifier": "t_type$_t_enum$_EventEmissionType_$4627_$",
                          "typeString": "type(enum IGenericTraderProxyV1.EventEmissionType)"
                        }
                      },
                      "id": 11593,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": true,
                      "lValueRequested": false,
                      "memberName": "MarginPosition",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": null,
                      "src": "3245:54:52",
                      "typeDescriptions": {
                        "typeIdentifier": "t_enum$_EventEmissionType_$4627",
                        "typeString": "enum IGenericTraderProxyV1.EventEmissionType"
                      }
                    },
                    "src": "3231:68:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "falseBody": null,
                  "id": 11603,
                  "nodeType": "IfStatement",
                  "src": "3227:255:52",
                  "trueBody": {
                    "id": 11602,
                    "nodeType": "Block",
                    "src": "3301:181:52",
                    "statements": [
                      {
                        "expression": {
                          "argumentTypes": null,
                          "arguments": [
                            {
                              "argumentTypes": null,
                              "id": 11596,
                              "name": "_cache",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 11562,
                              "src": "3356:6:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "id": 11597,
                              "name": "_tradeAccount",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 11564,
                              "src": "3380:13:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                                "typeString": "struct Account.Info memory"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "id": 11598,
                              "name": "_marketIdsPath",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 11567,
                              "src": "3411:14:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                                "typeString": "uint256[] memory"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "id": 11599,
                              "name": "_transferParam",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 11572,
                              "src": "3443:14:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_TransferCollateralParam_$4640_memory_ptr",
                                "typeString": "struct IGenericTraderProxyV1.TransferCollateralParam memory"
                              }
                            }
                          ],
                          "expression": {
                            "argumentTypes": [
                              {
                                "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                              },
                              {
                                "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                                "typeString": "struct Account.Info memory"
                              },
                              {
                                "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                                "typeString": "uint256[] memory"
                              },
                              {
                                "typeIdentifier": "t_struct$_TransferCollateralParam_$4640_memory_ptr",
                                "typeString": "struct IGenericTraderProxyV1.TransferCollateralParam memory"
                              }
                            ],
                            "id": 11595,
                            "name": "_logMarginPositionEvent",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 11827,
                            "src": "3315:23:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_function_internal_nonpayable$_t_struct$_GenericTraderProxyCache_$4607_memory_ptr_$_t_struct$_Info_$24851_memory_ptr_$_t_array$_t_uint256_$dyn_memory_ptr_$_t_struct$_TransferCollateralParam_$4640_memory_ptr_$returns$__$",
                              "typeString": "function (struct IGenericTraderProxyBase.GenericTraderProxyCache memory,struct Account.Info memory,uint256[] memory,struct IGenericTraderProxyV1.TransferCollateralParam memory)"
                            }
                          },
                          "id": 11600,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "kind": "functionCall",
                          "lValueRequested": false,
                          "names": [],
                          "nodeType": "FunctionCall",
                          "src": "3315:156:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_tuple$__$",
                            "typeString": "tuple()"
                          }
                        },
                        "id": 11601,
                        "nodeType": "ExpressionStatement",
                        "src": "3315:156:52"
                      }
                    ]
                  }
                }
              ]
            },
            "documentation": null,
            "id": 11605,
            "implemented": true,
            "kind": "function",
            "modifiers": [],
            "name": "logAfterZapEvents",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 11575,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 11562,
                  "name": "_cache",
                  "nodeType": "VariableDeclaration",
                  "scope": 11605,
                  "src": "2669:61:52",
                  "stateVariable": false,
                  "storageLocation": "memory",
                  "typeDescriptions": {
                    "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                    "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache"
                  },
                  "typeName": {
                    "contractScope": null,
                    "id": 11561,
                    "name": "IGenericTraderProxyBase.GenericTraderProxyCache",
                    "nodeType": "UserDefinedTypeName",
                    "referencedDeclaration": 4607,
                    "src": "2669:47:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_storage_ptr",
                      "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 11564,
                  "name": "_tradeAccount",
                  "nodeType": "VariableDeclaration",
                  "scope": 11605,
                  "src": "2740:33:52",
                  "stateVariable": false,
                  "storageLocation": "memory",
                  "typeDescriptions": {
                    "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                    "typeString": "struct Account.Info"
                  },
                  "typeName": {
                    "contractScope": null,
                    "id": 11563,
                    "name": "Account.Info",
                    "nodeType": "UserDefinedTypeName",
                    "referencedDeclaration": 24851,
                    "src": "2740:12:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_struct$_Info_$24851_storage_ptr",
                      "typeString": "struct Account.Info"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 11567,
                  "name": "_marketIdsPath",
                  "nodeType": "VariableDeclaration",
                  "scope": 11605,
                  "src": "2783:31:52",
                  "stateVariable": false,
                  "storageLocation": "memory",
                  "typeDescriptions": {
                    "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                    "typeString": "uint256[]"
                  },
                  "typeName": {
                    "baseType": {
                      "id": 11565,
                      "name": "uint256",
                      "nodeType": "ElementaryTypeName",
                      "src": "2783:7:52",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "id": 11566,
                    "length": null,
                    "nodeType": "ArrayTypeName",
                    "src": "2783:9:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_array$_t_uint256_$dyn_storage_ptr",
                      "typeString": "uint256[]"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 11570,
                  "name": "_tradersPath",
                  "nodeType": "VariableDeclaration",
                  "scope": 11605,
                  "src": "2824:57:52",
                  "stateVariable": false,
                  "storageLocation": "memory",
                  "typeDescriptions": {
                    "typeIdentifier": "t_array$_t_struct$_TraderParam_$4588_memory_$dyn_memory_ptr",
                    "typeString": "struct IGenericTraderProxyBase.TraderParam[]"
                  },
                  "typeName": {
                    "baseType": {
                      "contractScope": null,
                      "id": 11568,
                      "name": "IGenericTraderProxyBase.TraderParam",
                      "nodeType": "UserDefinedTypeName",
                      "referencedDeclaration": 4588,
                      "src": "2824:35:52",
                      "typeDescriptions": {
                        "typeIdentifier": "t_struct$_TraderParam_$4588_storage_ptr",
                        "typeString": "struct IGenericTraderProxyBase.TraderParam"
                      }
                    },
                    "id": 11569,
                    "length": null,
                    "nodeType": "ArrayTypeName",
                    "src": "2824:37:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_array$_t_struct$_TraderParam_$4588_storage_$dyn_storage_ptr",
                      "typeString": "struct IGenericTraderProxyBase.TraderParam[]"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 11572,
                  "name": "_transferParam",
                  "nodeType": "VariableDeclaration",
                  "scope": 11605,
                  "src": "2891:67:52",
                  "stateVariable": false,
                  "storageLocation": "memory",
                  "typeDescriptions": {
                    "typeIdentifier": "t_struct$_TransferCollateralParam_$4640_memory_ptr",
                    "typeString": "struct IGenericTraderProxyV1.TransferCollateralParam"
                  },
                  "typeName": {
                    "contractScope": null,
                    "id": 11571,
                    "name": "IGenericTraderProxyV1.TransferCollateralParam",
                    "nodeType": "UserDefinedTypeName",
                    "referencedDeclaration": 4640,
                    "src": "2891:45:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_struct$_TransferCollateralParam_$4640_storage_ptr",
                      "typeString": "struct IGenericTraderProxyV1.TransferCollateralParam"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 11574,
                  "name": "_eventType",
                  "nodeType": "VariableDeclaration",
                  "scope": 11605,
                  "src": "2968:50:52",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_enum$_EventEmissionType_$4627",
                    "typeString": "enum IGenericTraderProxyV1.EventEmissionType"
                  },
                  "typeName": {
                    "contractScope": null,
                    "id": 11573,
                    "name": "IGenericTraderProxyV1.EventEmissionType",
                    "nodeType": "UserDefinedTypeName",
                    "referencedDeclaration": 4627,
                    "src": "2968:39:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_enum$_EventEmissionType_$4627",
                      "typeString": "enum IGenericTraderProxyV1.EventEmissionType"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "2659:365:52"
            },
            "returnParameters": {
              "id": 11576,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "3032:0:52"
            },
            "scope": 11828,
            "src": "2633:855:52",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "public"
          },
          {
            "body": {
              "id": 11826,
              "nodeType": "Block",
              "src": "3766:3233:52",
              "statements": [
                {
                  "assignments": [
                    11620
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 11620,
                      "name": "inputBalanceUpdate",
                      "nodeType": "VariableDeclaration",
                      "scope": 11826,
                      "src": "3776:46:52",
                      "stateVariable": false,
                      "storageLocation": "memory",
                      "typeDescriptions": {
                        "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                        "typeString": "struct Events.BalanceUpdate"
                      },
                      "typeName": {
                        "contractScope": null,
                        "id": 11619,
                        "name": "Events.BalanceUpdate",
                        "nodeType": "UserDefinedTypeName",
                        "referencedDeclaration": 26624,
                        "src": "3776:20:52",
                        "typeDescriptions": {
                          "typeIdentifier": "t_struct$_BalanceUpdate_$26624_storage_ptr",
                          "typeString": "struct Events.BalanceUpdate"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 11621,
                  "initialValue": null,
                  "nodeType": "VariableDeclarationStatement",
                  "src": "3776:46:52"
                },
                {
                  "id": 11654,
                  "nodeType": "Block",
                  "src": "3870:455:52",
                  "statements": [
                    {
                      "assignments": [
                        11625
                      ],
                      "declarations": [
                        {
                          "constant": false,
                          "id": 11625,
                          "name": "inputBalanceWeiAfter",
                          "nodeType": "VariableDeclaration",
                          "scope": 11654,
                          "src": "3884:37:52",
                          "stateVariable": false,
                          "storageLocation": "memory",
                          "typeDescriptions": {
                            "typeIdentifier": "t_struct$_Wei_$31149_memory_ptr",
                            "typeString": "struct Types.Wei"
                          },
                          "typeName": {
                            "contractScope": null,
                            "id": 11624,
                            "name": "Types.Wei",
                            "nodeType": "UserDefinedTypeName",
                            "referencedDeclaration": 31149,
                            "src": "3884:9:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_struct$_Wei_$31149_storage_ptr",
                              "typeString": "struct Types.Wei"
                            }
                          },
                          "value": null,
                          "visibility": "internal"
                        }
                      ],
                      "id": 11634,
                      "initialValue": {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "id": 11629,
                            "name": "_tradeAccount",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 11609,
                            "src": "3977:13:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                              "typeString": "struct Account.Info memory"
                            }
                          },
                          {
                            "argumentTypes": null,
                            "baseExpression": {
                              "argumentTypes": null,
                              "id": 11630,
                              "name": "_marketIdsPath",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 11612,
                              "src": "4028:14:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                                "typeString": "uint256[] memory"
                              }
                            },
                            "id": 11632,
                            "indexExpression": {
                              "argumentTypes": null,
                              "hexValue": "30",
                              "id": 11631,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": true,
                              "kind": "number",
                              "lValueRequested": false,
                              "nodeType": "Literal",
                              "src": "4043:1:52",
                              "subdenomination": null,
                              "typeDescriptions": {
                                "typeIdentifier": "t_rational_0_by_1",
                                "typeString": "int_const 0"
                              },
                              "value": "0"
                            },
                            "isConstant": false,
                            "isLValue": true,
                            "isPure": false,
                            "lValueRequested": false,
                            "nodeType": "IndexAccess",
                            "src": "4028:17:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                              "typeString": "struct Account.Info memory"
                            },
                            {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          ],
                          "expression": {
                            "argumentTypes": null,
                            "expression": {
                              "argumentTypes": null,
                              "id": 11626,
                              "name": "_cache",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 11607,
                              "src": "3924:6:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                              }
                            },
                            "id": 11627,
                            "isConstant": false,
                            "isLValue": true,
                            "isPure": false,
                            "lValueRequested": false,
                            "memberName": "dolomiteMargin",
                            "nodeType": "MemberAccess",
                            "referencedDeclaration": 4590,
                            "src": "3924:21:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_contract$_IDolomiteMargin_$24693",
                              "typeString": "contract IDolomiteMargin"
                            }
                          },
                          "id": 11628,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "memberName": "getAccountWei",
                          "nodeType": "MemberAccess",
                          "referencedDeclaration": 24407,
                          "src": "3924:35:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_function_external_view$_t_struct$_Info_$24851_memory_ptr_$_t_uint256_$returns$_t_struct$_Wei_$31149_memory_ptr_$",
                            "typeString": "function (struct Account.Info memory,uint256) view external returns (struct Types.Wei memory)"
                          }
                        },
                        "id": 11633,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "functionCall",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "3924:135:52",
                        "typeDescriptions": {
                          "typeIdentifier": "t_struct$_Wei_$31149_memory_ptr",
                          "typeString": "struct Types.Wei memory"
                        }
                      },
                      "nodeType": "VariableDeclarationStatement",
                      "src": "3884:175:52"
                    },
                    {
                      "expression": {
                        "argumentTypes": null,
                        "id": 11652,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "leftHandSide": {
                          "argumentTypes": null,
                          "id": 11635,
                          "name": "inputBalanceUpdate",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 11620,
                          "src": "4073:18:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                            "typeString": "struct Events.BalanceUpdate memory"
                          }
                        },
                        "nodeType": "Assignment",
                        "operator": "=",
                        "rightHandSide": {
                          "argumentTypes": null,
                          "arguments": [
                            {
                              "argumentTypes": null,
                              "arguments": [
                                {
                                  "argumentTypes": null,
                                  "expression": {
                                    "argumentTypes": null,
                                    "id": 11640,
                                    "name": "_cache",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11607,
                                    "src": "4168:6:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                      "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                                    }
                                  },
                                  "id": 11641,
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "memberName": "inputBalanceWeiBeforeOperate",
                                  "nodeType": "MemberAccess",
                                  "referencedDeclaration": 4602,
                                  "src": "4168:35:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_struct$_Wei_$31149_memory",
                                    "typeString": "struct Types.Wei memory"
                                  }
                                }
                              ],
                              "expression": {
                                "argumentTypes": [
                                  {
                                    "typeIdentifier": "t_struct$_Wei_$31149_memory",
                                    "typeString": "struct Types.Wei memory"
                                  }
                                ],
                                "expression": {
                                  "argumentTypes": null,
                                  "id": 11638,
                                  "name": "inputBalanceWeiAfter",
                                  "nodeType": "Identifier",
                                  "overloadedDeclarations": [],
                                  "referencedDeclaration": 11625,
                                  "src": "4143:20:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_struct$_Wei_$31149_memory_ptr",
                                    "typeString": "struct Types.Wei memory"
                                  }
                                },
                                "id": 11639,
                                "isConstant": false,
                                "isLValue": true,
                                "isPure": false,
                                "lValueRequested": false,
                                "memberName": "sub",
                                "nodeType": "MemberAccess",
                                "referencedDeclaration": 31177,
                                "src": "4143:24:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_function_internal_pure$_t_struct$_Wei_$31149_memory_ptr_$_t_struct$_Wei_$31149_memory_ptr_$returns$_t_struct$_Wei_$31149_memory_ptr_$bound_to$_t_struct$_Wei_$31149_memory_ptr_$",
                                  "typeString": "function (struct Types.Wei memory,struct Types.Wei memory) pure returns (struct Types.Wei memory)"
                                }
                              },
                              "id": 11642,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "kind": "functionCall",
                              "lValueRequested": false,
                              "names": [],
                              "nodeType": "FunctionCall",
                              "src": "4143:61:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_Wei_$31149_memory_ptr",
                                "typeString": "struct Types.Wei memory"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "arguments": [
                                {
                                  "argumentTypes": null,
                                  "id": 11646,
                                  "name": "_tradeAccount",
                                  "nodeType": "Identifier",
                                  "overloadedDeclarations": [],
                                  "referencedDeclaration": 11609,
                                  "src": "4266:13:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                                    "typeString": "struct Account.Info memory"
                                  }
                                },
                                {
                                  "argumentTypes": null,
                                  "baseExpression": {
                                    "argumentTypes": null,
                                    "id": 11647,
                                    "name": "_marketIdsPath",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11612,
                                    "src": "4281:14:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                                      "typeString": "uint256[] memory"
                                    }
                                  },
                                  "id": 11649,
                                  "indexExpression": {
                                    "argumentTypes": null,
                                    "hexValue": "30",
                                    "id": 11648,
                                    "isConstant": false,
                                    "isLValue": false,
                                    "isPure": true,
                                    "kind": "number",
                                    "lValueRequested": false,
                                    "nodeType": "Literal",
                                    "src": "4296:1:52",
                                    "subdenomination": null,
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_rational_0_by_1",
                                      "typeString": "int_const 0"
                                    },
                                    "value": "0"
                                  },
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "nodeType": "IndexAccess",
                                  "src": "4281:17:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                }
                              ],
                              "expression": {
                                "argumentTypes": [
                                  {
                                    "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                                    "typeString": "struct Account.Info memory"
                                  },
                                  {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                ],
                                "expression": {
                                  "argumentTypes": null,
                                  "expression": {
                                    "argumentTypes": null,
                                    "id": 11643,
                                    "name": "_cache",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11607,
                                    "src": "4230:6:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                      "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                                    }
                                  },
                                  "id": 11644,
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "memberName": "dolomiteMargin",
                                  "nodeType": "MemberAccess",
                                  "referencedDeclaration": 4590,
                                  "src": "4230:21:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_contract$_IDolomiteMargin_$24693",
                                    "typeString": "contract IDolomiteMargin"
                                  }
                                },
                                "id": 11645,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": false,
                                "lValueRequested": false,
                                "memberName": "getAccountPar",
                                "nodeType": "MemberAccess",
                                "referencedDeclaration": 24398,
                                "src": "4230:35:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_function_external_view$_t_struct$_Info_$24851_memory_ptr_$_t_uint256_$returns$_t_struct$_Par_$30890_memory_ptr_$",
                                  "typeString": "function (struct Account.Info memory,uint256) view external returns (struct Types.Par memory)"
                                }
                              },
                              "id": 11650,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "kind": "functionCall",
                              "lValueRequested": false,
                              "names": [],
                              "nodeType": "FunctionCall",
                              "src": "4230:69:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_Par_$30890_memory_ptr",
                                "typeString": "struct Types.Par memory"
                              }
                            }
                          ],
                          "expression": {
                            "argumentTypes": [
                              {
                                "typeIdentifier": "t_struct$_Wei_$31149_memory_ptr",
                                "typeString": "struct Types.Wei memory"
                              },
                              {
                                "typeIdentifier": "t_struct$_Par_$30890_memory_ptr",
                                "typeString": "struct Types.Par memory"
                              }
                            ],
                            "expression": {
                              "argumentTypes": null,
                              "id": 11636,
                              "name": "Events",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 27153,
                              "src": "4094:6:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_type$_t_contract$_Events_$27153_$",
                                "typeString": "type(library Events)"
                              }
                            },
                            "id": 11637,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": false,
                            "lValueRequested": false,
                            "memberName": "BalanceUpdate",
                            "nodeType": "MemberAccess",
                            "referencedDeclaration": 26624,
                            "src": "4094:20:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_type$_t_struct$_BalanceUpdate_$26624_storage_ptr_$",
                              "typeString": "type(struct Events.BalanceUpdate storage pointer)"
                            }
                          },
                          "id": 11651,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "kind": "structConstructorCall",
                          "lValueRequested": false,
                          "names": [
                            "deltaWei",
                            "newPar"
                          ],
                          "nodeType": "FunctionCall",
                          "src": "4094:220:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory",
                            "typeString": "struct Events.BalanceUpdate memory"
                          }
                        },
                        "src": "4073:241:52",
                        "typeDescriptions": {
                          "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                          "typeString": "struct Events.BalanceUpdate memory"
                        }
                      },
                      "id": 11653,
                      "nodeType": "ExpressionStatement",
                      "src": "4073:241:52"
                    }
                  ]
                },
                {
                  "assignments": [
                    11658
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 11658,
                      "name": "outputBalanceUpdate",
                      "nodeType": "VariableDeclaration",
                      "scope": 11826,
                      "src": "4372:47:52",
                      "stateVariable": false,
                      "storageLocation": "memory",
                      "typeDescriptions": {
                        "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                        "typeString": "struct Events.BalanceUpdate"
                      },
                      "typeName": {
                        "contractScope": null,
                        "id": 11657,
                        "name": "Events.BalanceUpdate",
                        "nodeType": "UserDefinedTypeName",
                        "referencedDeclaration": 26624,
                        "src": "4372:20:52",
                        "typeDescriptions": {
                          "typeIdentifier": "t_struct$_BalanceUpdate_$26624_storage_ptr",
                          "typeString": "struct Events.BalanceUpdate"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 11659,
                  "initialValue": null,
                  "nodeType": "VariableDeclarationStatement",
                  "src": "4372:47:52"
                },
                {
                  "id": 11698,
                  "nodeType": "Block",
                  "src": "4467:508:52",
                  "statements": [
                    {
                      "assignments": [
                        11663
                      ],
                      "declarations": [
                        {
                          "constant": false,
                          "id": 11663,
                          "name": "outputBalanceWeiAfter",
                          "nodeType": "VariableDeclaration",
                          "scope": 11698,
                          "src": "4481:38:52",
                          "stateVariable": false,
                          "storageLocation": "memory",
                          "typeDescriptions": {
                            "typeIdentifier": "t_struct$_Wei_$31149_memory_ptr",
                            "typeString": "struct Types.Wei"
                          },
                          "typeName": {
                            "contractScope": null,
                            "id": 11662,
                            "name": "Types.Wei",
                            "nodeType": "UserDefinedTypeName",
                            "referencedDeclaration": 31149,
                            "src": "4481:9:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_struct$_Wei_$31149_storage_ptr",
                              "typeString": "struct Types.Wei"
                            }
                          },
                          "value": null,
                          "visibility": "internal"
                        }
                      ],
                      "id": 11675,
                      "initialValue": {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "id": 11667,
                            "name": "_tradeAccount",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 11609,
                            "src": "4575:13:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                              "typeString": "struct Account.Info memory"
                            }
                          },
                          {
                            "argumentTypes": null,
                            "baseExpression": {
                              "argumentTypes": null,
                              "id": 11668,
                              "name": "_marketIdsPath",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 11612,
                              "src": "4627:14:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                                "typeString": "uint256[] memory"
                              }
                            },
                            "id": 11673,
                            "indexExpression": {
                              "argumentTypes": null,
                              "commonType": {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              },
                              "id": 11672,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "lValueRequested": false,
                              "leftExpression": {
                                "argumentTypes": null,
                                "expression": {
                                  "argumentTypes": null,
                                  "id": 11669,
                                  "name": "_marketIdsPath",
                                  "nodeType": "Identifier",
                                  "overloadedDeclarations": [],
                                  "referencedDeclaration": 11612,
                                  "src": "4642:14:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                                    "typeString": "uint256[] memory"
                                  }
                                },
                                "id": 11670,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": false,
                                "lValueRequested": false,
                                "memberName": "length",
                                "nodeType": "MemberAccess",
                                "referencedDeclaration": null,
                                "src": "4642:21:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_uint256",
                                  "typeString": "uint256"
                                }
                              },
                              "nodeType": "BinaryOperation",
                              "operator": "-",
                              "rightExpression": {
                                "argumentTypes": null,
                                "hexValue": "31",
                                "id": 11671,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": true,
                                "kind": "number",
                                "lValueRequested": false,
                                "nodeType": "Literal",
                                "src": "4666:1:52",
                                "subdenomination": null,
                                "typeDescriptions": {
                                  "typeIdentifier": "t_rational_1_by_1",
                                  "typeString": "int_const 1"
                                },
                                "value": "1"
                              },
                              "src": "4642:25:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              }
                            },
                            "isConstant": false,
                            "isLValue": true,
                            "isPure": false,
                            "lValueRequested": false,
                            "nodeType": "IndexAccess",
                            "src": "4627:41:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                              "typeString": "struct Account.Info memory"
                            },
                            {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          ],
                          "expression": {
                            "argumentTypes": null,
                            "expression": {
                              "argumentTypes": null,
                              "id": 11664,
                              "name": "_cache",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 11607,
                              "src": "4522:6:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                              }
                            },
                            "id": 11665,
                            "isConstant": false,
                            "isLValue": true,
                            "isPure": false,
                            "lValueRequested": false,
                            "memberName": "dolomiteMargin",
                            "nodeType": "MemberAccess",
                            "referencedDeclaration": 4590,
                            "src": "4522:21:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_contract$_IDolomiteMargin_$24693",
                              "typeString": "contract IDolomiteMargin"
                            }
                          },
                          "id": 11666,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "memberName": "getAccountWei",
                          "nodeType": "MemberAccess",
                          "referencedDeclaration": 24407,
                          "src": "4522:35:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_function_external_view$_t_struct$_Info_$24851_memory_ptr_$_t_uint256_$returns$_t_struct$_Wei_$31149_memory_ptr_$",
                            "typeString": "function (struct Account.Info memory,uint256) view external returns (struct Types.Wei memory)"
                          }
                        },
                        "id": 11674,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "functionCall",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "4522:160:52",
                        "typeDescriptions": {
                          "typeIdentifier": "t_struct$_Wei_$31149_memory_ptr",
                          "typeString": "struct Types.Wei memory"
                        }
                      },
                      "nodeType": "VariableDeclarationStatement",
                      "src": "4481:201:52"
                    },
                    {
                      "expression": {
                        "argumentTypes": null,
                        "id": 11696,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "leftHandSide": {
                          "argumentTypes": null,
                          "id": 11676,
                          "name": "outputBalanceUpdate",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 11658,
                          "src": "4696:19:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                            "typeString": "struct Events.BalanceUpdate memory"
                          }
                        },
                        "nodeType": "Assignment",
                        "operator": "=",
                        "rightHandSide": {
                          "argumentTypes": null,
                          "arguments": [
                            {
                              "argumentTypes": null,
                              "arguments": [
                                {
                                  "argumentTypes": null,
                                  "expression": {
                                    "argumentTypes": null,
                                    "id": 11681,
                                    "name": "_cache",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11607,
                                    "src": "4793:6:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                      "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                                    }
                                  },
                                  "id": 11682,
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "memberName": "outputBalanceWeiBeforeOperate",
                                  "nodeType": "MemberAccess",
                                  "referencedDeclaration": 4604,
                                  "src": "4793:36:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_struct$_Wei_$31149_memory",
                                    "typeString": "struct Types.Wei memory"
                                  }
                                }
                              ],
                              "expression": {
                                "argumentTypes": [
                                  {
                                    "typeIdentifier": "t_struct$_Wei_$31149_memory",
                                    "typeString": "struct Types.Wei memory"
                                  }
                                ],
                                "expression": {
                                  "argumentTypes": null,
                                  "id": 11679,
                                  "name": "outputBalanceWeiAfter",
                                  "nodeType": "Identifier",
                                  "overloadedDeclarations": [],
                                  "referencedDeclaration": 11663,
                                  "src": "4767:21:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_struct$_Wei_$31149_memory_ptr",
                                    "typeString": "struct Types.Wei memory"
                                  }
                                },
                                "id": 11680,
                                "isConstant": false,
                                "isLValue": true,
                                "isPure": false,
                                "lValueRequested": false,
                                "memberName": "sub",
                                "nodeType": "MemberAccess",
                                "referencedDeclaration": 31177,
                                "src": "4767:25:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_function_internal_pure$_t_struct$_Wei_$31149_memory_ptr_$_t_struct$_Wei_$31149_memory_ptr_$returns$_t_struct$_Wei_$31149_memory_ptr_$bound_to$_t_struct$_Wei_$31149_memory_ptr_$",
                                  "typeString": "function (struct Types.Wei memory,struct Types.Wei memory) pure returns (struct Types.Wei memory)"
                                }
                              },
                              "id": 11683,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "kind": "functionCall",
                              "lValueRequested": false,
                              "names": [],
                              "nodeType": "FunctionCall",
                              "src": "4767:63:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_Wei_$31149_memory_ptr",
                                "typeString": "struct Types.Wei memory"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "arguments": [
                                {
                                  "argumentTypes": null,
                                  "id": 11687,
                                  "name": "_tradeAccount",
                                  "nodeType": "Identifier",
                                  "overloadedDeclarations": [],
                                  "referencedDeclaration": 11609,
                                  "src": "4892:13:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                                    "typeString": "struct Account.Info memory"
                                  }
                                },
                                {
                                  "argumentTypes": null,
                                  "baseExpression": {
                                    "argumentTypes": null,
                                    "id": 11688,
                                    "name": "_marketIdsPath",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11612,
                                    "src": "4907:14:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                                      "typeString": "uint256[] memory"
                                    }
                                  },
                                  "id": 11693,
                                  "indexExpression": {
                                    "argumentTypes": null,
                                    "commonType": {
                                      "typeIdentifier": "t_uint256",
                                      "typeString": "uint256"
                                    },
                                    "id": 11692,
                                    "isConstant": false,
                                    "isLValue": false,
                                    "isPure": false,
                                    "lValueRequested": false,
                                    "leftExpression": {
                                      "argumentTypes": null,
                                      "expression": {
                                        "argumentTypes": null,
                                        "id": 11689,
                                        "name": "_marketIdsPath",
                                        "nodeType": "Identifier",
                                        "overloadedDeclarations": [],
                                        "referencedDeclaration": 11612,
                                        "src": "4922:14:52",
                                        "typeDescriptions": {
                                          "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                                          "typeString": "uint256[] memory"
                                        }
                                      },
                                      "id": 11690,
                                      "isConstant": false,
                                      "isLValue": false,
                                      "isPure": false,
                                      "lValueRequested": false,
                                      "memberName": "length",
                                      "nodeType": "MemberAccess",
                                      "referencedDeclaration": null,
                                      "src": "4922:21:52",
                                      "typeDescriptions": {
                                        "typeIdentifier": "t_uint256",
                                        "typeString": "uint256"
                                      }
                                    },
                                    "nodeType": "BinaryOperation",
                                    "operator": "-",
                                    "rightExpression": {
                                      "argumentTypes": null,
                                      "hexValue": "31",
                                      "id": 11691,
                                      "isConstant": false,
                                      "isLValue": false,
                                      "isPure": true,
                                      "kind": "number",
                                      "lValueRequested": false,
                                      "nodeType": "Literal",
                                      "src": "4946:1:52",
                                      "subdenomination": null,
                                      "typeDescriptions": {
                                        "typeIdentifier": "t_rational_1_by_1",
                                        "typeString": "int_const 1"
                                      },
                                      "value": "1"
                                    },
                                    "src": "4922:25:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_uint256",
                                      "typeString": "uint256"
                                    }
                                  },
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "nodeType": "IndexAccess",
                                  "src": "4907:41:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                }
                              ],
                              "expression": {
                                "argumentTypes": [
                                  {
                                    "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                                    "typeString": "struct Account.Info memory"
                                  },
                                  {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                ],
                                "expression": {
                                  "argumentTypes": null,
                                  "expression": {
                                    "argumentTypes": null,
                                    "id": 11684,
                                    "name": "_cache",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11607,
                                    "src": "4856:6:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                      "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                                    }
                                  },
                                  "id": 11685,
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "memberName": "dolomiteMargin",
                                  "nodeType": "MemberAccess",
                                  "referencedDeclaration": 4590,
                                  "src": "4856:21:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_contract$_IDolomiteMargin_$24693",
                                    "typeString": "contract IDolomiteMargin"
                                  }
                                },
                                "id": 11686,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": false,
                                "lValueRequested": false,
                                "memberName": "getAccountPar",
                                "nodeType": "MemberAccess",
                                "referencedDeclaration": 24398,
                                "src": "4856:35:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_function_external_view$_t_struct$_Info_$24851_memory_ptr_$_t_uint256_$returns$_t_struct$_Par_$30890_memory_ptr_$",
                                  "typeString": "function (struct Account.Info memory,uint256) view external returns (struct Types.Par memory)"
                                }
                              },
                              "id": 11694,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "kind": "functionCall",
                              "lValueRequested": false,
                              "names": [],
                              "nodeType": "FunctionCall",
                              "src": "4856:93:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_Par_$30890_memory_ptr",
                                "typeString": "struct Types.Par memory"
                              }
                            }
                          ],
                          "expression": {
                            "argumentTypes": [
                              {
                                "typeIdentifier": "t_struct$_Wei_$31149_memory_ptr",
                                "typeString": "struct Types.Wei memory"
                              },
                              {
                                "typeIdentifier": "t_struct$_Par_$30890_memory_ptr",
                                "typeString": "struct Types.Par memory"
                              }
                            ],
                            "expression": {
                              "argumentTypes": null,
                              "id": 11677,
                              "name": "Events",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 27153,
                              "src": "4718:6:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_type$_t_contract$_Events_$27153_$",
                                "typeString": "type(library Events)"
                              }
                            },
                            "id": 11678,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": false,
                            "lValueRequested": false,
                            "memberName": "BalanceUpdate",
                            "nodeType": "MemberAccess",
                            "referencedDeclaration": 26624,
                            "src": "4718:20:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_type$_t_struct$_BalanceUpdate_$26624_storage_ptr_$",
                              "typeString": "type(struct Events.BalanceUpdate storage pointer)"
                            }
                          },
                          "id": 11695,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "kind": "structConstructorCall",
                          "lValueRequested": false,
                          "names": [
                            "deltaWei",
                            "newPar"
                          ],
                          "nodeType": "FunctionCall",
                          "src": "4718:246:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory",
                            "typeString": "struct Events.BalanceUpdate memory"
                          }
                        },
                        "src": "4696:268:52",
                        "typeDescriptions": {
                          "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                          "typeString": "struct Events.BalanceUpdate memory"
                        }
                      },
                      "id": 11697,
                      "nodeType": "ExpressionStatement",
                      "src": "4696:268:52"
                    }
                  ]
                },
                {
                  "assignments": [
                    11702
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 11702,
                      "name": "marginBalanceUpdate",
                      "nodeType": "VariableDeclaration",
                      "scope": 11826,
                      "src": "5022:47:52",
                      "stateVariable": false,
                      "storageLocation": "memory",
                      "typeDescriptions": {
                        "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                        "typeString": "struct Events.BalanceUpdate"
                      },
                      "typeName": {
                        "contractScope": null,
                        "id": 11701,
                        "name": "Events.BalanceUpdate",
                        "nodeType": "UserDefinedTypeName",
                        "referencedDeclaration": 26624,
                        "src": "5022:20:52",
                        "typeDescriptions": {
                          "typeIdentifier": "t_struct$_BalanceUpdate_$26624_storage_ptr",
                          "typeString": "struct Events.BalanceUpdate"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 11703,
                  "initialValue": null,
                  "nodeType": "VariableDeclarationStatement",
                  "src": "5022:47:52"
                },
                {
                  "id": 11740,
                  "nodeType": "Block",
                  "src": "5117:555:52",
                  "statements": [
                    {
                      "assignments": [
                        11707
                      ],
                      "declarations": [
                        {
                          "constant": false,
                          "id": 11707,
                          "name": "marginBalanceWeiAfter",
                          "nodeType": "VariableDeclaration",
                          "scope": 11740,
                          "src": "5131:38:52",
                          "stateVariable": false,
                          "storageLocation": "memory",
                          "typeDescriptions": {
                            "typeIdentifier": "t_struct$_Wei_$31149_memory_ptr",
                            "typeString": "struct Types.Wei"
                          },
                          "typeName": {
                            "contractScope": null,
                            "id": 11706,
                            "name": "Types.Wei",
                            "nodeType": "UserDefinedTypeName",
                            "referencedDeclaration": 31149,
                            "src": "5131:9:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_struct$_Wei_$31149_storage_ptr",
                              "typeString": "struct Types.Wei"
                            }
                          },
                          "value": null,
                          "visibility": "internal"
                        }
                      ],
                      "id": 11718,
                      "initialValue": {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "id": 11711,
                            "name": "_tradeAccount",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 11609,
                            "src": "5225:13:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                              "typeString": "struct Account.Info memory"
                            }
                          },
                          {
                            "argumentTypes": null,
                            "expression": {
                              "argumentTypes": null,
                              "baseExpression": {
                                "argumentTypes": null,
                                "expression": {
                                  "argumentTypes": null,
                                  "id": 11712,
                                  "name": "_param",
                                  "nodeType": "Identifier",
                                  "overloadedDeclarations": [],
                                  "referencedDeclaration": 11614,
                                  "src": "5278:6:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_struct$_TransferCollateralParam_$4640_memory_ptr",
                                    "typeString": "struct IGenericTraderProxyV1.TransferCollateralParam memory"
                                  }
                                },
                                "id": 11713,
                                "isConstant": false,
                                "isLValue": true,
                                "isPure": false,
                                "lValueRequested": false,
                                "memberName": "transferAmounts",
                                "nodeType": "MemberAccess",
                                "referencedDeclaration": 4639,
                                "src": "5278:22:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_array$_t_struct$_TransferAmount_$4632_memory_$dyn_memory",
                                  "typeString": "struct IGenericTraderProxyV1.TransferAmount memory[] memory"
                                }
                              },
                              "id": 11715,
                              "indexExpression": {
                                "argumentTypes": null,
                                "hexValue": "30",
                                "id": 11714,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": true,
                                "kind": "number",
                                "lValueRequested": false,
                                "nodeType": "Literal",
                                "src": "5301:1:52",
                                "subdenomination": null,
                                "typeDescriptions": {
                                  "typeIdentifier": "t_rational_0_by_1",
                                  "typeString": "int_const 0"
                                },
                                "value": "0"
                              },
                              "isConstant": false,
                              "isLValue": true,
                              "isPure": false,
                              "lValueRequested": false,
                              "nodeType": "IndexAccess",
                              "src": "5278:25:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_TransferAmount_$4632_memory",
                                "typeString": "struct IGenericTraderProxyV1.TransferAmount memory"
                              }
                            },
                            "id": 11716,
                            "isConstant": false,
                            "isLValue": true,
                            "isPure": false,
                            "lValueRequested": false,
                            "memberName": "marketId",
                            "nodeType": "MemberAccess",
                            "referencedDeclaration": 4629,
                            "src": "5278:34:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                              "typeString": "struct Account.Info memory"
                            },
                            {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          ],
                          "expression": {
                            "argumentTypes": null,
                            "expression": {
                              "argumentTypes": null,
                              "id": 11708,
                              "name": "_cache",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 11607,
                              "src": "5172:6:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                              }
                            },
                            "id": 11709,
                            "isConstant": false,
                            "isLValue": true,
                            "isPure": false,
                            "lValueRequested": false,
                            "memberName": "dolomiteMargin",
                            "nodeType": "MemberAccess",
                            "referencedDeclaration": 4590,
                            "src": "5172:21:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_contract$_IDolomiteMargin_$24693",
                              "typeString": "contract IDolomiteMargin"
                            }
                          },
                          "id": 11710,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "memberName": "getAccountWei",
                          "nodeType": "MemberAccess",
                          "referencedDeclaration": 24407,
                          "src": "5172:35:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_function_external_view$_t_struct$_Info_$24851_memory_ptr_$_t_uint256_$returns$_t_struct$_Wei_$31149_memory_ptr_$",
                            "typeString": "function (struct Account.Info memory,uint256) view external returns (struct Types.Wei memory)"
                          }
                        },
                        "id": 11717,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "functionCall",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "5172:154:52",
                        "typeDescriptions": {
                          "typeIdentifier": "t_struct$_Wei_$31149_memory_ptr",
                          "typeString": "struct Types.Wei memory"
                        }
                      },
                      "nodeType": "VariableDeclarationStatement",
                      "src": "5131:195:52"
                    },
                    {
                      "expression": {
                        "argumentTypes": null,
                        "id": 11738,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "leftHandSide": {
                          "argumentTypes": null,
                          "id": 11719,
                          "name": "marginBalanceUpdate",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 11702,
                          "src": "5340:19:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                            "typeString": "struct Events.BalanceUpdate memory"
                          }
                        },
                        "nodeType": "Assignment",
                        "operator": "=",
                        "rightHandSide": {
                          "argumentTypes": null,
                          "arguments": [
                            {
                              "argumentTypes": null,
                              "arguments": [
                                {
                                  "argumentTypes": null,
                                  "expression": {
                                    "argumentTypes": null,
                                    "id": 11724,
                                    "name": "_cache",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11607,
                                    "src": "5437:6:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                      "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                                    }
                                  },
                                  "id": 11725,
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "memberName": "transferBalanceWeiBeforeOperate",
                                  "nodeType": "MemberAccess",
                                  "referencedDeclaration": 4606,
                                  "src": "5437:38:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_struct$_Wei_$31149_memory",
                                    "typeString": "struct Types.Wei memory"
                                  }
                                }
                              ],
                              "expression": {
                                "argumentTypes": [
                                  {
                                    "typeIdentifier": "t_struct$_Wei_$31149_memory",
                                    "typeString": "struct Types.Wei memory"
                                  }
                                ],
                                "expression": {
                                  "argumentTypes": null,
                                  "id": 11722,
                                  "name": "marginBalanceWeiAfter",
                                  "nodeType": "Identifier",
                                  "overloadedDeclarations": [],
                                  "referencedDeclaration": 11707,
                                  "src": "5411:21:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_struct$_Wei_$31149_memory_ptr",
                                    "typeString": "struct Types.Wei memory"
                                  }
                                },
                                "id": 11723,
                                "isConstant": false,
                                "isLValue": true,
                                "isPure": false,
                                "lValueRequested": false,
                                "memberName": "sub",
                                "nodeType": "MemberAccess",
                                "referencedDeclaration": 31177,
                                "src": "5411:25:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_function_internal_pure$_t_struct$_Wei_$31149_memory_ptr_$_t_struct$_Wei_$31149_memory_ptr_$returns$_t_struct$_Wei_$31149_memory_ptr_$bound_to$_t_struct$_Wei_$31149_memory_ptr_$",
                                  "typeString": "function (struct Types.Wei memory,struct Types.Wei memory) pure returns (struct Types.Wei memory)"
                                }
                              },
                              "id": 11726,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "kind": "functionCall",
                              "lValueRequested": false,
                              "names": [],
                              "nodeType": "FunctionCall",
                              "src": "5411:65:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_Wei_$31149_memory_ptr",
                                "typeString": "struct Types.Wei memory"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "arguments": [
                                {
                                  "argumentTypes": null,
                                  "id": 11730,
                                  "name": "_tradeAccount",
                                  "nodeType": "Identifier",
                                  "overloadedDeclarations": [],
                                  "referencedDeclaration": 11609,
                                  "src": "5559:13:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                                    "typeString": "struct Account.Info memory"
                                  }
                                },
                                {
                                  "argumentTypes": null,
                                  "expression": {
                                    "argumentTypes": null,
                                    "baseExpression": {
                                      "argumentTypes": null,
                                      "expression": {
                                        "argumentTypes": null,
                                        "id": 11731,
                                        "name": "_param",
                                        "nodeType": "Identifier",
                                        "overloadedDeclarations": [],
                                        "referencedDeclaration": 11614,
                                        "src": "5594:6:52",
                                        "typeDescriptions": {
                                          "typeIdentifier": "t_struct$_TransferCollateralParam_$4640_memory_ptr",
                                          "typeString": "struct IGenericTraderProxyV1.TransferCollateralParam memory"
                                        }
                                      },
                                      "id": 11732,
                                      "isConstant": false,
                                      "isLValue": true,
                                      "isPure": false,
                                      "lValueRequested": false,
                                      "memberName": "transferAmounts",
                                      "nodeType": "MemberAccess",
                                      "referencedDeclaration": 4639,
                                      "src": "5594:22:52",
                                      "typeDescriptions": {
                                        "typeIdentifier": "t_array$_t_struct$_TransferAmount_$4632_memory_$dyn_memory",
                                        "typeString": "struct IGenericTraderProxyV1.TransferAmount memory[] memory"
                                      }
                                    },
                                    "id": 11734,
                                    "indexExpression": {
                                      "argumentTypes": null,
                                      "hexValue": "30",
                                      "id": 11733,
                                      "isConstant": false,
                                      "isLValue": false,
                                      "isPure": true,
                                      "kind": "number",
                                      "lValueRequested": false,
                                      "nodeType": "Literal",
                                      "src": "5617:1:52",
                                      "subdenomination": null,
                                      "typeDescriptions": {
                                        "typeIdentifier": "t_rational_0_by_1",
                                        "typeString": "int_const 0"
                                      },
                                      "value": "0"
                                    },
                                    "isConstant": false,
                                    "isLValue": true,
                                    "isPure": false,
                                    "lValueRequested": false,
                                    "nodeType": "IndexAccess",
                                    "src": "5594:25:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_struct$_TransferAmount_$4632_memory",
                                      "typeString": "struct IGenericTraderProxyV1.TransferAmount memory"
                                    }
                                  },
                                  "id": 11735,
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "memberName": "marketId",
                                  "nodeType": "MemberAccess",
                                  "referencedDeclaration": 4629,
                                  "src": "5594:34:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                }
                              ],
                              "expression": {
                                "argumentTypes": [
                                  {
                                    "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                                    "typeString": "struct Account.Info memory"
                                  },
                                  {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                ],
                                "expression": {
                                  "argumentTypes": null,
                                  "expression": {
                                    "argumentTypes": null,
                                    "id": 11727,
                                    "name": "_cache",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11607,
                                    "src": "5502:6:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                      "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                                    }
                                  },
                                  "id": 11728,
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "memberName": "dolomiteMargin",
                                  "nodeType": "MemberAccess",
                                  "referencedDeclaration": 4590,
                                  "src": "5502:21:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_contract$_IDolomiteMargin_$24693",
                                    "typeString": "contract IDolomiteMargin"
                                  }
                                },
                                "id": 11729,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": false,
                                "lValueRequested": false,
                                "memberName": "getAccountPar",
                                "nodeType": "MemberAccess",
                                "referencedDeclaration": 24398,
                                "src": "5502:35:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_function_external_view$_t_struct$_Info_$24851_memory_ptr_$_t_uint256_$returns$_t_struct$_Par_$30890_memory_ptr_$",
                                  "typeString": "function (struct Account.Info memory,uint256) view external returns (struct Types.Par memory)"
                                }
                              },
                              "id": 11736,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "kind": "functionCall",
                              "lValueRequested": false,
                              "names": [],
                              "nodeType": "FunctionCall",
                              "src": "5502:144:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_Par_$30890_memory_ptr",
                                "typeString": "struct Types.Par memory"
                              }
                            }
                          ],
                          "expression": {
                            "argumentTypes": [
                              {
                                "typeIdentifier": "t_struct$_Wei_$31149_memory_ptr",
                                "typeString": "struct Types.Wei memory"
                              },
                              {
                                "typeIdentifier": "t_struct$_Par_$30890_memory_ptr",
                                "typeString": "struct Types.Par memory"
                              }
                            ],
                            "expression": {
                              "argumentTypes": null,
                              "id": 11720,
                              "name": "Events",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 27153,
                              "src": "5362:6:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_type$_t_contract$_Events_$27153_$",
                                "typeString": "type(library Events)"
                              }
                            },
                            "id": 11721,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": false,
                            "lValueRequested": false,
                            "memberName": "BalanceUpdate",
                            "nodeType": "MemberAccess",
                            "referencedDeclaration": 26624,
                            "src": "5362:20:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_type$_t_struct$_BalanceUpdate_$26624_storage_ptr_$",
                              "typeString": "type(struct Events.BalanceUpdate storage pointer)"
                            }
                          },
                          "id": 11737,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "kind": "structConstructorCall",
                          "lValueRequested": false,
                          "names": [
                            "deltaWei",
                            "newPar"
                          ],
                          "nodeType": "FunctionCall",
                          "src": "5362:299:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory",
                            "typeString": "struct Events.BalanceUpdate memory"
                          }
                        },
                        "src": "5340:321:52",
                        "typeDescriptions": {
                          "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                          "typeString": "struct Events.BalanceUpdate memory"
                        }
                      },
                      "id": 11739,
                      "nodeType": "ExpressionStatement",
                      "src": "5340:321:52"
                    }
                  ]
                },
                {
                  "condition": {
                    "argumentTypes": null,
                    "expression": {
                      "argumentTypes": null,
                      "id": 11741,
                      "name": "_cache",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 11607,
                      "src": "5723:6:52",
                      "typeDescriptions": {
                        "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                        "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                      }
                    },
                    "id": 11742,
                    "isConstant": false,
                    "isLValue": true,
                    "isPure": false,
                    "lValueRequested": false,
                    "memberName": "isMarginDeposit",
                    "nodeType": "MemberAccess",
                    "referencedDeclaration": 4594,
                    "src": "5723:22:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "falseBody": {
                    "id": 11824,
                    "nodeType": "Block",
                    "src": "6371:622:52",
                    "statements": [
                      {
                        "expression": {
                          "argumentTypes": null,
                          "arguments": [
                            {
                              "argumentTypes": null,
                              "expression": {
                                "argumentTypes": null,
                                "id": 11789,
                                "name": "_tradeAccount",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 11609,
                                "src": "6454:13:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                                  "typeString": "struct Account.Info memory"
                                }
                              },
                              "id": 11790,
                              "isConstant": false,
                              "isLValue": true,
                              "isPure": false,
                              "lValueRequested": false,
                              "memberName": "owner",
                              "nodeType": "MemberAccess",
                              "referencedDeclaration": 24848,
                              "src": "6454:19:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "expression": {
                                "argumentTypes": null,
                                "id": 11791,
                                "name": "_tradeAccount",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 11609,
                                "src": "6491:13:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                                  "typeString": "struct Account.Info memory"
                                }
                              },
                              "id": 11792,
                              "isConstant": false,
                              "isLValue": true,
                              "isPure": false,
                              "lValueRequested": false,
                              "memberName": "number",
                              "nodeType": "MemberAccess",
                              "referencedDeclaration": 24850,
                              "src": "6491:20:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "arguments": [
                                {
                                  "argumentTypes": null,
                                  "baseExpression": {
                                    "argumentTypes": null,
                                    "id": 11796,
                                    "name": "_marketIdsPath",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11612,
                                    "src": "6593:14:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                                      "typeString": "uint256[] memory"
                                    }
                                  },
                                  "id": 11798,
                                  "indexExpression": {
                                    "argumentTypes": null,
                                    "hexValue": "30",
                                    "id": 11797,
                                    "isConstant": false,
                                    "isLValue": false,
                                    "isPure": true,
                                    "kind": "number",
                                    "lValueRequested": false,
                                    "nodeType": "Literal",
                                    "src": "6608:1:52",
                                    "subdenomination": null,
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_rational_0_by_1",
                                      "typeString": "int_const 0"
                                    },
                                    "value": "0"
                                  },
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "nodeType": "IndexAccess",
                                  "src": "6593:17:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                }
                              ],
                              "expression": {
                                "argumentTypes": [
                                  {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                ],
                                "expression": {
                                  "argumentTypes": null,
                                  "expression": {
                                    "argumentTypes": null,
                                    "id": 11793,
                                    "name": "_cache",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11607,
                                    "src": "6549:6:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                      "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                                    }
                                  },
                                  "id": 11794,
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "memberName": "dolomiteMargin",
                                  "nodeType": "MemberAccess",
                                  "referencedDeclaration": 4590,
                                  "src": "6549:21:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_contract$_IDolomiteMargin_$24693",
                                    "typeString": "contract IDolomiteMargin"
                                  }
                                },
                                "id": 11795,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": false,
                                "lValueRequested": false,
                                "memberName": "getMarketTokenAddress",
                                "nodeType": "MemberAccess",
                                "referencedDeclaration": 24229,
                                "src": "6549:43:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_function_external_view$_t_uint256_$returns$_t_address_$",
                                  "typeString": "function (uint256) view external returns (address)"
                                }
                              },
                              "id": 11799,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "kind": "functionCall",
                              "lValueRequested": false,
                              "names": [],
                              "nodeType": "FunctionCall",
                              "src": "6549:62:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "arguments": [
                                {
                                  "argumentTypes": null,
                                  "baseExpression": {
                                    "argumentTypes": null,
                                    "id": 11803,
                                    "name": "_marketIdsPath",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11612,
                                    "src": "6694:14:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                                      "typeString": "uint256[] memory"
                                    }
                                  },
                                  "id": 11808,
                                  "indexExpression": {
                                    "argumentTypes": null,
                                    "commonType": {
                                      "typeIdentifier": "t_uint256",
                                      "typeString": "uint256"
                                    },
                                    "id": 11807,
                                    "isConstant": false,
                                    "isLValue": false,
                                    "isPure": false,
                                    "lValueRequested": false,
                                    "leftExpression": {
                                      "argumentTypes": null,
                                      "expression": {
                                        "argumentTypes": null,
                                        "id": 11804,
                                        "name": "_marketIdsPath",
                                        "nodeType": "Identifier",
                                        "overloadedDeclarations": [],
                                        "referencedDeclaration": 11612,
                                        "src": "6709:14:52",
                                        "typeDescriptions": {
                                          "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                                          "typeString": "uint256[] memory"
                                        }
                                      },
                                      "id": 11805,
                                      "isConstant": false,
                                      "isLValue": false,
                                      "isPure": false,
                                      "lValueRequested": false,
                                      "memberName": "length",
                                      "nodeType": "MemberAccess",
                                      "referencedDeclaration": null,
                                      "src": "6709:21:52",
                                      "typeDescriptions": {
                                        "typeIdentifier": "t_uint256",
                                        "typeString": "uint256"
                                      }
                                    },
                                    "nodeType": "BinaryOperation",
                                    "operator": "-",
                                    "rightExpression": {
                                      "argumentTypes": null,
                                      "hexValue": "31",
                                      "id": 11806,
                                      "isConstant": false,
                                      "isLValue": false,
                                      "isPure": true,
                                      "kind": "number",
                                      "lValueRequested": false,
                                      "nodeType": "Literal",
                                      "src": "6733:1:52",
                                      "subdenomination": null,
                                      "typeDescriptions": {
                                        "typeIdentifier": "t_rational_1_by_1",
                                        "typeString": "int_const 1"
                                      },
                                      "value": "1"
                                    },
                                    "src": "6709:25:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_uint256",
                                      "typeString": "uint256"
                                    }
                                  },
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "nodeType": "IndexAccess",
                                  "src": "6694:41:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                }
                              ],
                              "expression": {
                                "argumentTypes": [
                                  {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                ],
                                "expression": {
                                  "argumentTypes": null,
                                  "expression": {
                                    "argumentTypes": null,
                                    "id": 11800,
                                    "name": "_cache",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11607,
                                    "src": "6650:6:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                      "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                                    }
                                  },
                                  "id": 11801,
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "memberName": "dolomiteMargin",
                                  "nodeType": "MemberAccess",
                                  "referencedDeclaration": 4590,
                                  "src": "6650:21:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_contract$_IDolomiteMargin_$24693",
                                    "typeString": "contract IDolomiteMargin"
                                  }
                                },
                                "id": 11802,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": false,
                                "lValueRequested": false,
                                "memberName": "getMarketTokenAddress",
                                "nodeType": "MemberAccess",
                                "referencedDeclaration": 24229,
                                "src": "6650:43:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_function_external_view$_t_uint256_$returns$_t_address_$",
                                  "typeString": "function (uint256) view external returns (address)"
                                }
                              },
                              "id": 11809,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "kind": "functionCall",
                              "lValueRequested": false,
                              "names": [],
                              "nodeType": "FunctionCall",
                              "src": "6650:86:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "arguments": [
                                {
                                  "argumentTypes": null,
                                  "expression": {
                                    "argumentTypes": null,
                                    "baseExpression": {
                                      "argumentTypes": null,
                                      "expression": {
                                        "argumentTypes": null,
                                        "id": 11813,
                                        "name": "_param",
                                        "nodeType": "Identifier",
                                        "overloadedDeclarations": [],
                                        "referencedDeclaration": 11614,
                                        "src": "6823:6:52",
                                        "typeDescriptions": {
                                          "typeIdentifier": "t_struct$_TransferCollateralParam_$4640_memory_ptr",
                                          "typeString": "struct IGenericTraderProxyV1.TransferCollateralParam memory"
                                        }
                                      },
                                      "id": 11814,
                                      "isConstant": false,
                                      "isLValue": true,
                                      "isPure": false,
                                      "lValueRequested": false,
                                      "memberName": "transferAmounts",
                                      "nodeType": "MemberAccess",
                                      "referencedDeclaration": 4639,
                                      "src": "6823:22:52",
                                      "typeDescriptions": {
                                        "typeIdentifier": "t_array$_t_struct$_TransferAmount_$4632_memory_$dyn_memory",
                                        "typeString": "struct IGenericTraderProxyV1.TransferAmount memory[] memory"
                                      }
                                    },
                                    "id": 11816,
                                    "indexExpression": {
                                      "argumentTypes": null,
                                      "hexValue": "30",
                                      "id": 11815,
                                      "isConstant": false,
                                      "isLValue": false,
                                      "isPure": true,
                                      "kind": "number",
                                      "lValueRequested": false,
                                      "nodeType": "Literal",
                                      "src": "6846:1:52",
                                      "subdenomination": null,
                                      "typeDescriptions": {
                                        "typeIdentifier": "t_rational_0_by_1",
                                        "typeString": "int_const 0"
                                      },
                                      "value": "0"
                                    },
                                    "isConstant": false,
                                    "isLValue": true,
                                    "isPure": false,
                                    "lValueRequested": false,
                                    "nodeType": "IndexAccess",
                                    "src": "6823:25:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_struct$_TransferAmount_$4632_memory",
                                      "typeString": "struct IGenericTraderProxyV1.TransferAmount memory"
                                    }
                                  },
                                  "id": 11817,
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "memberName": "marketId",
                                  "nodeType": "MemberAccess",
                                  "referencedDeclaration": 4629,
                                  "src": "6823:34:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                }
                              ],
                              "expression": {
                                "argumentTypes": [
                                  {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                ],
                                "expression": {
                                  "argumentTypes": null,
                                  "expression": {
                                    "argumentTypes": null,
                                    "id": 11810,
                                    "name": "_cache",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11607,
                                    "src": "6779:6:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                      "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                                    }
                                  },
                                  "id": 11811,
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "memberName": "dolomiteMargin",
                                  "nodeType": "MemberAccess",
                                  "referencedDeclaration": 4590,
                                  "src": "6779:21:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_contract$_IDolomiteMargin_$24693",
                                    "typeString": "contract IDolomiteMargin"
                                  }
                                },
                                "id": 11812,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": false,
                                "lValueRequested": false,
                                "memberName": "getMarketTokenAddress",
                                "nodeType": "MemberAccess",
                                "referencedDeclaration": 24229,
                                "src": "6779:43:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_function_external_view$_t_uint256_$returns$_t_address_$",
                                  "typeString": "function (uint256) view external returns (address)"
                                }
                              },
                              "id": 11818,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "kind": "functionCall",
                              "lValueRequested": false,
                              "names": [],
                              "nodeType": "FunctionCall",
                              "src": "6779:79:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "id": 11819,
                              "name": "inputBalanceUpdate",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 11620,
                              "src": "6876:18:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                                "typeString": "struct Events.BalanceUpdate memory"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "id": 11820,
                              "name": "outputBalanceUpdate",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 11658,
                              "src": "6912:19:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                                "typeString": "struct Events.BalanceUpdate memory"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "id": 11821,
                              "name": "marginBalanceUpdate",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 11702,
                              "src": "6949:19:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                                "typeString": "struct Events.BalanceUpdate memory"
                              }
                            }
                          ],
                          "expression": {
                            "argumentTypes": [
                              {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              },
                              {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              },
                              {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              },
                              {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              },
                              {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              },
                              {
                                "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                                "typeString": "struct Events.BalanceUpdate memory"
                              },
                              {
                                "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                                "typeString": "struct Events.BalanceUpdate memory"
                              },
                              {
                                "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                                "typeString": "struct Events.BalanceUpdate memory"
                              }
                            ],
                            "expression": {
                              "argumentTypes": null,
                              "expression": {
                                "argumentTypes": null,
                                "id": 11784,
                                "name": "_cache",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 11607,
                                "src": "6385:6:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                  "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                                }
                              },
                              "id": 11787,
                              "isConstant": false,
                              "isLValue": true,
                              "isPure": false,
                              "lValueRequested": false,
                              "memberName": "eventEmitterRegistry",
                              "nodeType": "MemberAccess",
                              "referencedDeclaration": 4592,
                              "src": "6385:27:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_contract$_IEventEmitterRegistry_$4498",
                                "typeString": "contract IEventEmitterRegistry"
                              }
                            },
                            "id": 11788,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": false,
                            "lValueRequested": false,
                            "memberName": "emitMarginPositionClose",
                            "nodeType": "MemberAccess",
                            "referencedDeclaration": 4497,
                            "src": "6385:51:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$_t_address_$_t_address_$_t_address_$_t_struct$_BalanceUpdate_$26624_memory_ptr_$_t_struct$_BalanceUpdate_$26624_memory_ptr_$_t_struct$_BalanceUpdate_$26624_memory_ptr_$returns$__$",
                              "typeString": "function (address,uint256,address,address,address,struct Events.BalanceUpdate memory,struct Events.BalanceUpdate memory,struct Events.BalanceUpdate memory) external"
                            }
                          },
                          "id": 11822,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "kind": "functionCall",
                          "lValueRequested": false,
                          "names": [],
                          "nodeType": "FunctionCall",
                          "src": "6385:597:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_tuple$__$",
                            "typeString": "tuple()"
                          }
                        },
                        "id": 11823,
                        "nodeType": "ExpressionStatement",
                        "src": "6385:597:52"
                      }
                    ]
                  },
                  "id": 11825,
                  "nodeType": "IfStatement",
                  "src": "5719:1274:52",
                  "trueBody": {
                    "id": 11783,
                    "nodeType": "Block",
                    "src": "5747:618:52",
                    "statements": [
                      {
                        "expression": {
                          "argumentTypes": null,
                          "arguments": [
                            {
                              "argumentTypes": null,
                              "expression": {
                                "argumentTypes": null,
                                "id": 11748,
                                "name": "_tradeAccount",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 11609,
                                "src": "5829:13:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                                  "typeString": "struct Account.Info memory"
                                }
                              },
                              "id": 11749,
                              "isConstant": false,
                              "isLValue": true,
                              "isPure": false,
                              "lValueRequested": false,
                              "memberName": "owner",
                              "nodeType": "MemberAccess",
                              "referencedDeclaration": 24848,
                              "src": "5829:19:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "expression": {
                                "argumentTypes": null,
                                "id": 11750,
                                "name": "_tradeAccount",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 11609,
                                "src": "5866:13:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                                  "typeString": "struct Account.Info memory"
                                }
                              },
                              "id": 11751,
                              "isConstant": false,
                              "isLValue": true,
                              "isPure": false,
                              "lValueRequested": false,
                              "memberName": "number",
                              "nodeType": "MemberAccess",
                              "referencedDeclaration": 24850,
                              "src": "5866:20:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "arguments": [
                                {
                                  "argumentTypes": null,
                                  "baseExpression": {
                                    "argumentTypes": null,
                                    "id": 11755,
                                    "name": "_marketIdsPath",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11612,
                                    "src": "5968:14:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                                      "typeString": "uint256[] memory"
                                    }
                                  },
                                  "id": 11757,
                                  "indexExpression": {
                                    "argumentTypes": null,
                                    "hexValue": "30",
                                    "id": 11756,
                                    "isConstant": false,
                                    "isLValue": false,
                                    "isPure": true,
                                    "kind": "number",
                                    "lValueRequested": false,
                                    "nodeType": "Literal",
                                    "src": "5983:1:52",
                                    "subdenomination": null,
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_rational_0_by_1",
                                      "typeString": "int_const 0"
                                    },
                                    "value": "0"
                                  },
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "nodeType": "IndexAccess",
                                  "src": "5968:17:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                }
                              ],
                              "expression": {
                                "argumentTypes": [
                                  {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                ],
                                "expression": {
                                  "argumentTypes": null,
                                  "expression": {
                                    "argumentTypes": null,
                                    "id": 11752,
                                    "name": "_cache",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11607,
                                    "src": "5924:6:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                      "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                                    }
                                  },
                                  "id": 11753,
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "memberName": "dolomiteMargin",
                                  "nodeType": "MemberAccess",
                                  "referencedDeclaration": 4590,
                                  "src": "5924:21:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_contract$_IDolomiteMargin_$24693",
                                    "typeString": "contract IDolomiteMargin"
                                  }
                                },
                                "id": 11754,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": false,
                                "lValueRequested": false,
                                "memberName": "getMarketTokenAddress",
                                "nodeType": "MemberAccess",
                                "referencedDeclaration": 24229,
                                "src": "5924:43:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_function_external_view$_t_uint256_$returns$_t_address_$",
                                  "typeString": "function (uint256) view external returns (address)"
                                }
                              },
                              "id": 11758,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "kind": "functionCall",
                              "lValueRequested": false,
                              "names": [],
                              "nodeType": "FunctionCall",
                              "src": "5924:62:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "arguments": [
                                {
                                  "argumentTypes": null,
                                  "baseExpression": {
                                    "argumentTypes": null,
                                    "id": 11762,
                                    "name": "_marketIdsPath",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11612,
                                    "src": "6069:14:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                                      "typeString": "uint256[] memory"
                                    }
                                  },
                                  "id": 11767,
                                  "indexExpression": {
                                    "argumentTypes": null,
                                    "commonType": {
                                      "typeIdentifier": "t_uint256",
                                      "typeString": "uint256"
                                    },
                                    "id": 11766,
                                    "isConstant": false,
                                    "isLValue": false,
                                    "isPure": false,
                                    "lValueRequested": false,
                                    "leftExpression": {
                                      "argumentTypes": null,
                                      "expression": {
                                        "argumentTypes": null,
                                        "id": 11763,
                                        "name": "_marketIdsPath",
                                        "nodeType": "Identifier",
                                        "overloadedDeclarations": [],
                                        "referencedDeclaration": 11612,
                                        "src": "6084:14:52",
                                        "typeDescriptions": {
                                          "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                                          "typeString": "uint256[] memory"
                                        }
                                      },
                                      "id": 11764,
                                      "isConstant": false,
                                      "isLValue": false,
                                      "isPure": false,
                                      "lValueRequested": false,
                                      "memberName": "length",
                                      "nodeType": "MemberAccess",
                                      "referencedDeclaration": null,
                                      "src": "6084:21:52",
                                      "typeDescriptions": {
                                        "typeIdentifier": "t_uint256",
                                        "typeString": "uint256"
                                      }
                                    },
                                    "nodeType": "BinaryOperation",
                                    "operator": "-",
                                    "rightExpression": {
                                      "argumentTypes": null,
                                      "hexValue": "31",
                                      "id": 11765,
                                      "isConstant": false,
                                      "isLValue": false,
                                      "isPure": true,
                                      "kind": "number",
                                      "lValueRequested": false,
                                      "nodeType": "Literal",
                                      "src": "6108:1:52",
                                      "subdenomination": null,
                                      "typeDescriptions": {
                                        "typeIdentifier": "t_rational_1_by_1",
                                        "typeString": "int_const 1"
                                      },
                                      "value": "1"
                                    },
                                    "src": "6084:25:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_uint256",
                                      "typeString": "uint256"
                                    }
                                  },
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "nodeType": "IndexAccess",
                                  "src": "6069:41:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                }
                              ],
                              "expression": {
                                "argumentTypes": [
                                  {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                ],
                                "expression": {
                                  "argumentTypes": null,
                                  "expression": {
                                    "argumentTypes": null,
                                    "id": 11759,
                                    "name": "_cache",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11607,
                                    "src": "6025:6:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                      "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                                    }
                                  },
                                  "id": 11760,
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "memberName": "dolomiteMargin",
                                  "nodeType": "MemberAccess",
                                  "referencedDeclaration": 4590,
                                  "src": "6025:21:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_contract$_IDolomiteMargin_$24693",
                                    "typeString": "contract IDolomiteMargin"
                                  }
                                },
                                "id": 11761,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": false,
                                "lValueRequested": false,
                                "memberName": "getMarketTokenAddress",
                                "nodeType": "MemberAccess",
                                "referencedDeclaration": 24229,
                                "src": "6025:43:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_function_external_view$_t_uint256_$returns$_t_address_$",
                                  "typeString": "function (uint256) view external returns (address)"
                                }
                              },
                              "id": 11768,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "kind": "functionCall",
                              "lValueRequested": false,
                              "names": [],
                              "nodeType": "FunctionCall",
                              "src": "6025:86:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "arguments": [
                                {
                                  "argumentTypes": null,
                                  "expression": {
                                    "argumentTypes": null,
                                    "baseExpression": {
                                      "argumentTypes": null,
                                      "expression": {
                                        "argumentTypes": null,
                                        "id": 11772,
                                        "name": "_param",
                                        "nodeType": "Identifier",
                                        "overloadedDeclarations": [],
                                        "referencedDeclaration": 11614,
                                        "src": "6195:6:52",
                                        "typeDescriptions": {
                                          "typeIdentifier": "t_struct$_TransferCollateralParam_$4640_memory_ptr",
                                          "typeString": "struct IGenericTraderProxyV1.TransferCollateralParam memory"
                                        }
                                      },
                                      "id": 11773,
                                      "isConstant": false,
                                      "isLValue": true,
                                      "isPure": false,
                                      "lValueRequested": false,
                                      "memberName": "transferAmounts",
                                      "nodeType": "MemberAccess",
                                      "referencedDeclaration": 4639,
                                      "src": "6195:22:52",
                                      "typeDescriptions": {
                                        "typeIdentifier": "t_array$_t_struct$_TransferAmount_$4632_memory_$dyn_memory",
                                        "typeString": "struct IGenericTraderProxyV1.TransferAmount memory[] memory"
                                      }
                                    },
                                    "id": 11775,
                                    "indexExpression": {
                                      "argumentTypes": null,
                                      "hexValue": "30",
                                      "id": 11774,
                                      "isConstant": false,
                                      "isLValue": false,
                                      "isPure": true,
                                      "kind": "number",
                                      "lValueRequested": false,
                                      "nodeType": "Literal",
                                      "src": "6218:1:52",
                                      "subdenomination": null,
                                      "typeDescriptions": {
                                        "typeIdentifier": "t_rational_0_by_1",
                                        "typeString": "int_const 0"
                                      },
                                      "value": "0"
                                    },
                                    "isConstant": false,
                                    "isLValue": true,
                                    "isPure": false,
                                    "lValueRequested": false,
                                    "nodeType": "IndexAccess",
                                    "src": "6195:25:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_struct$_TransferAmount_$4632_memory",
                                      "typeString": "struct IGenericTraderProxyV1.TransferAmount memory"
                                    }
                                  },
                                  "id": 11776,
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "memberName": "marketId",
                                  "nodeType": "MemberAccess",
                                  "referencedDeclaration": 4629,
                                  "src": "6195:34:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                }
                              ],
                              "expression": {
                                "argumentTypes": [
                                  {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                ],
                                "expression": {
                                  "argumentTypes": null,
                                  "expression": {
                                    "argumentTypes": null,
                                    "id": 11769,
                                    "name": "_cache",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11607,
                                    "src": "6151:6:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                      "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                                    }
                                  },
                                  "id": 11770,
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "memberName": "dolomiteMargin",
                                  "nodeType": "MemberAccess",
                                  "referencedDeclaration": 4590,
                                  "src": "6151:21:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_contract$_IDolomiteMargin_$24693",
                                    "typeString": "contract IDolomiteMargin"
                                  }
                                },
                                "id": 11771,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": false,
                                "lValueRequested": false,
                                "memberName": "getMarketTokenAddress",
                                "nodeType": "MemberAccess",
                                "referencedDeclaration": 24229,
                                "src": "6151:43:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_function_external_view$_t_uint256_$returns$_t_address_$",
                                  "typeString": "function (uint256) view external returns (address)"
                                }
                              },
                              "id": 11777,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "kind": "functionCall",
                              "lValueRequested": false,
                              "names": [],
                              "nodeType": "FunctionCall",
                              "src": "6151:79:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "id": 11778,
                              "name": "inputBalanceUpdate",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 11620,
                              "src": "6248:18:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                                "typeString": "struct Events.BalanceUpdate memory"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "id": 11779,
                              "name": "outputBalanceUpdate",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 11658,
                              "src": "6284:19:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                                "typeString": "struct Events.BalanceUpdate memory"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "id": 11780,
                              "name": "marginBalanceUpdate",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 11702,
                              "src": "6321:19:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                                "typeString": "struct Events.BalanceUpdate memory"
                              }
                            }
                          ],
                          "expression": {
                            "argumentTypes": [
                              {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              },
                              {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              },
                              {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              },
                              {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              },
                              {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              },
                              {
                                "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                                "typeString": "struct Events.BalanceUpdate memory"
                              },
                              {
                                "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                                "typeString": "struct Events.BalanceUpdate memory"
                              },
                              {
                                "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                                "typeString": "struct Events.BalanceUpdate memory"
                              }
                            ],
                            "expression": {
                              "argumentTypes": null,
                              "expression": {
                                "argumentTypes": null,
                                "id": 11743,
                                "name": "_cache",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 11607,
                                "src": "5761:6:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                  "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                                }
                              },
                              "id": 11746,
                              "isConstant": false,
                              "isLValue": true,
                              "isPure": false,
                              "lValueRequested": false,
                              "memberName": "eventEmitterRegistry",
                              "nodeType": "MemberAccess",
                              "referencedDeclaration": 4592,
                              "src": "5761:27:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_contract$_IEventEmitterRegistry_$4498",
                                "typeString": "contract IEventEmitterRegistry"
                              }
                            },
                            "id": 11747,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": false,
                            "lValueRequested": false,
                            "memberName": "emitMarginPositionOpen",
                            "nodeType": "MemberAccess",
                            "referencedDeclaration": 4478,
                            "src": "5761:50:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$_t_address_$_t_address_$_t_address_$_t_struct$_BalanceUpdate_$26624_memory_ptr_$_t_struct$_BalanceUpdate_$26624_memory_ptr_$_t_struct$_BalanceUpdate_$26624_memory_ptr_$returns$__$",
                              "typeString": "function (address,uint256,address,address,address,struct Events.BalanceUpdate memory,struct Events.BalanceUpdate memory,struct Events.BalanceUpdate memory) external"
                            }
                          },
                          "id": 11781,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "kind": "functionCall",
                          "lValueRequested": false,
                          "names": [],
                          "nodeType": "FunctionCall",
                          "src": "5761:593:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_tuple$__$",
                            "typeString": "tuple()"
                          }
                        },
                        "id": 11782,
                        "nodeType": "ExpressionStatement",
                        "src": "5761:593:52"
                      }
                    ]
                  }
                }
              ]
            },
            "documentation": null,
            "id": 11827,
            "implemented": true,
            "kind": "function",
            "modifiers": [],
            "name": "_logMarginPositionEvent",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 11615,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 11607,
                  "name": "_cache",
                  "nodeType": "VariableDeclaration",
                  "scope": 11827,
                  "src": "3536:61:52",
                  "stateVariable": false,
                  "storageLocation": "memory",
                  "typeDescriptions": {
                    "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                    "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache"
                  },
                  "typeName": {
                    "contractScope": null,
                    "id": 11606,
                    "name": "IGenericTraderProxyBase.GenericTraderProxyCache",
                    "nodeType": "UserDefinedTypeName",
                    "referencedDeclaration": 4607,
                    "src": "3536:47:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_storage_ptr",
                      "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 11609,
                  "name": "_tradeAccount",
                  "nodeType": "VariableDeclaration",
                  "scope": 11827,
                  "src": "3607:33:52",
                  "stateVariable": false,
                  "storageLocation": "memory",
                  "typeDescriptions": {
                    "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                    "typeString": "struct Account.Info"
                  },
                  "typeName": {
                    "contractScope": null,
                    "id": 11608,
                    "name": "Account.Info",
                    "nodeType": "UserDefinedTypeName",
                    "referencedDeclaration": 24851,
                    "src": "3607:12:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_struct$_Info_$24851_storage_ptr",
                      "typeString": "struct Account.Info"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 11612,
                  "name": "_marketIdsPath",
                  "nodeType": "VariableDeclaration",
                  "scope": 11827,
                  "src": "3650:31:52",
                  "stateVariable": false,
                  "storageLocation": "memory",
                  "typeDescriptions": {
                    "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                    "typeString": "uint256[]"
                  },
                  "typeName": {
                    "baseType": {
                      "id": 11610,
                      "name": "uint256",
                      "nodeType": "ElementaryTypeName",
                      "src": "3650:7:52",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "id": 11611,
                    "length": null,
                    "nodeType": "ArrayTypeName",
                    "src": "3650:9:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_array$_t_uint256_$dyn_storage_ptr",
                      "typeString": "uint256[]"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 11614,
                  "name": "_param",
                  "nodeType": "VariableDeclaration",
                  "scope": 11827,
                  "src": "3691:59:52",
                  "stateVariable": false,
                  "storageLocation": "memory",
                  "typeDescriptions": {
                    "typeIdentifier": "t_struct$_TransferCollateralParam_$4640_memory_ptr",
                    "typeString": "struct IGenericTraderProxyV1.TransferCollateralParam"
                  },
                  "typeName": {
                    "contractScope": null,
                    "id": 11613,
                    "name": "IGenericTraderProxyV1.TransferCollateralParam",
                    "nodeType": "UserDefinedTypeName",
                    "referencedDeclaration": 4640,
                    "src": "3691:45:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_struct$_TransferCollateralParam_$4640_storage_ptr",
                      "typeString": "struct IGenericTraderProxyV1.TransferCollateralParam"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "3526:230:52"
            },
            "returnParameters": {
              "id": 11616,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "3766:0:52"
            },
            "scope": 11828,
            "src": "3494:3505:52",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "internal"
          }
        ],
        "scope": 11829,
        "src": "2035:4966:52"
      }
    ],
    "src": "595:6407:52"
  },
  "legacyAST": {
    "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/proxies/GenericTraderProxyV1Lib.sol",
    "exportedSymbols": {
      "GenericTraderProxyV1Lib": [
        11828
      ]
    },
    "id": 11829,
    "nodeType": "SourceUnit",
    "nodes": [
      {
        "id": 11494,
        "literals": [
          "solidity",
          "^",
          "0.5",
          ".7"
        ],
        "nodeType": "PragmaDirective",
        "src": "595:23:52"
      },
      {
        "id": 11495,
        "literals": [
          "experimental",
          "ABIEncoderV2"
        ],
        "nodeType": "PragmaDirective",
        "src": "619:33:52"
      },
      {
        "absolutePath": "@openzeppelin/contracts/utils/ReentrancyGuard.sol",
        "file": "@openzeppelin/contracts/utils/ReentrancyGuard.sol",
        "id": 11497,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 38093,
        "src": "654:84:52",
        "symbolAliases": [
          {
            "foreign": 11496,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/interfaces/IDolomiteMargin.sol",
        "file": "../../protocol/interfaces/IDolomiteMargin.sol",
        "id": 11499,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 24694,
        "src": "740:80:52",
        "symbolAliases": [
          {
            "foreign": 11498,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/lib/Account.sol",
        "file": "../../protocol/lib/Account.sol",
        "id": 11501,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 24886,
        "src": "822:57:52",
        "symbolAliases": [
          {
            "foreign": 11500,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/lib/Actions.sol",
        "file": "../../protocol/lib/Actions.sol",
        "id": 11503,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 25370,
        "src": "880:57:52",
        "symbolAliases": [
          {
            "foreign": 11502,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/lib/Events.sol",
        "file": "../../protocol/lib/Events.sol",
        "id": 11505,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 27154,
        "src": "938:55:52",
        "symbolAliases": [
          {
            "foreign": 11504,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/lib/Require.sol",
        "file": "../../protocol/lib/Require.sol",
        "id": 11507,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 28453,
        "src": "994:57:52",
        "symbolAliases": [
          {
            "foreign": 11506,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/protocol/lib/Types.sol",
        "file": "../../protocol/lib/Types.sol",
        "id": 11509,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 31362,
        "src": "1052:53:52",
        "symbolAliases": [
          {
            "foreign": 11508,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/helpers/HasLiquidatorRegistry.sol",
        "file": "../helpers/HasLiquidatorRegistry.sol",
        "id": 11511,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 1723,
        "src": "1107:77:52",
        "symbolAliases": [
          {
            "foreign": 11510,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/helpers/OnlyDolomiteMargin.sol",
        "file": "../helpers/OnlyDolomiteMargin.sol",
        "id": 11513,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 3067,
        "src": "1185:71:52",
        "symbolAliases": [
          {
            "foreign": 11512,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/interfaces/IExpiry.sol",
        "file": "../interfaces/IExpiry.sol",
        "id": 11515,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 4566,
        "src": "1258:52:52",
        "symbolAliases": [
          {
            "foreign": 11514,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/interfaces/IGenericTraderProxyBase.sol",
        "file": "../interfaces/IGenericTraderProxyBase.sol",
        "id": 11517,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 4609,
        "src": "1311:84:52",
        "symbolAliases": [
          {
            "foreign": 11516,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/interfaces/IGenericTraderProxyV1.sol",
        "file": "../interfaces/IGenericTraderProxyV1.sol",
        "id": 11519,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 4698,
        "src": "1396:80:52",
        "symbolAliases": [
          {
            "foreign": 11518,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/interfaces/IIsolationModeUnwrapperTrader.sol",
        "file": "../interfaces/IIsolationModeUnwrapperTrader.sol",
        "id": 11521,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 4771,
        "src": "1477:96:52",
        "symbolAliases": [
          {
            "foreign": 11520,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/interfaces/IIsolationModeWrapperTrader.sol",
        "file": "../interfaces/IIsolationModeWrapperTrader.sol",
        "id": 11523,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 4829,
        "src": "1574:92:52",
        "symbolAliases": [
          {
            "foreign": 11522,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/interfaces/IEventEmitterRegistry.sol",
        "file": "../interfaces/IEventEmitterRegistry.sol",
        "id": 11525,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 4499,
        "src": "1667:80:52",
        "symbolAliases": [
          {
            "foreign": 11524,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/lib/AccountActionLib.sol",
        "file": "../lib/AccountActionLib.sol",
        "id": 11527,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 5820,
        "src": "1749:63:52",
        "symbolAliases": [
          {
            "foreign": 11526,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/cdc218/projects/dolomite/dolomite-protocol-v2/contracts/external/lib/AccountBalanceLib.sol",
        "file": "../lib/AccountBalanceLib.sol",
        "id": 11529,
        "nodeType": "ImportDirective",
        "scope": 11829,
        "sourceUnit": 5892,
        "src": "1813:65:52",
        "symbolAliases": [
          {
            "foreign": 11528,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "baseContracts": [],
        "contractDependencies": [],
        "contractKind": "library",
        "documentation": "@title   GenericTraderProxyV1Lib\n@author  Dolomite\n * @dev Library contract for reducing code size of the GenericTraderProxyV1 contract",
        "fullyImplemented": true,
        "id": 11828,
        "linearizedBaseContracts": [
          11828
        ],
        "name": "GenericTraderProxyV1Lib",
        "nodeType": "ContractDefinition",
        "nodes": [
          {
            "id": 11532,
            "libraryName": {
              "contractScope": null,
              "id": 11530,
              "name": "Types",
              "nodeType": "UserDefinedTypeName",
              "referencedDeclaration": 31361,
              "src": "2079:5:52",
              "typeDescriptions": {
                "typeIdentifier": "t_contract$_Types_$31361",
                "typeString": "library Types"
              }
            },
            "nodeType": "UsingForDirective",
            "src": "2073:26:52",
            "typeName": {
              "contractScope": null,
              "id": 11531,
              "name": "Types.Wei",
              "nodeType": "UserDefinedTypeName",
              "referencedDeclaration": 31149,
              "src": "2089:9:52",
              "typeDescriptions": {
                "typeIdentifier": "t_struct$_Wei_$31149_storage_ptr",
                "typeString": "struct Types.Wei"
              }
            }
          },
          {
            "body": {
              "id": 11559,
              "nodeType": "Block",
              "src": "2373:254:52",
              "statements": [
                {
                  "condition": {
                    "argumentTypes": null,
                    "commonType": {
                      "typeIdentifier": "t_enum$_EventEmissionType_$4627",
                      "typeString": "enum IGenericTraderProxyV1.EventEmissionType"
                    },
                    "id": 11545,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftExpression": {
                      "argumentTypes": null,
                      "id": 11541,
                      "name": "_eventType",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 11538,
                      "src": "2387:10:52",
                      "typeDescriptions": {
                        "typeIdentifier": "t_enum$_EventEmissionType_$4627",
                        "typeString": "enum IGenericTraderProxyV1.EventEmissionType"
                      }
                    },
                    "nodeType": "BinaryOperation",
                    "operator": "==",
                    "rightExpression": {
                      "argumentTypes": null,
                      "expression": {
                        "argumentTypes": null,
                        "expression": {
                          "argumentTypes": null,
                          "id": 11542,
                          "name": "IGenericTraderProxyV1",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 4697,
                          "src": "2401:21:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_type$_t_contract$_IGenericTraderProxyV1_$4697_$",
                            "typeString": "type(contract IGenericTraderProxyV1)"
                          }
                        },
                        "id": 11543,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "EventEmissionType",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": 4627,
                        "src": "2401:39:52",
                        "typeDescriptions": {
                          "typeIdentifier": "t_type$_t_enum$_EventEmissionType_$4627_$",
                          "typeString": "type(enum IGenericTraderProxyV1.EventEmissionType)"
                        }
                      },
                      "id": 11544,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": true,
                      "lValueRequested": false,
                      "memberName": "BorrowPosition",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": null,
                      "src": "2401:54:52",
                      "typeDescriptions": {
                        "typeIdentifier": "t_enum$_EventEmissionType_$4627",
                        "typeString": "enum IGenericTraderProxyV1.EventEmissionType"
                      }
                    },
                    "src": "2387:68:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "falseBody": null,
                  "id": 11558,
                  "nodeType": "IfStatement",
                  "src": "2383:238:52",
                  "trueBody": {
                    "id": 11557,
                    "nodeType": "Block",
                    "src": "2457:164:52",
                    "statements": [
                      {
                        "expression": {
                          "argumentTypes": null,
                          "arguments": [
                            {
                              "argumentTypes": null,
                              "expression": {
                                "argumentTypes": null,
                                "id": 11551,
                                "name": "_tradeAccount",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 11536,
                                "src": "2539:13:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                                  "typeString": "struct Account.Info memory"
                                }
                              },
                              "id": 11552,
                              "isConstant": false,
                              "isLValue": true,
                              "isPure": false,
                              "lValueRequested": false,
                              "memberName": "owner",
                              "nodeType": "MemberAccess",
                              "referencedDeclaration": 24848,
                              "src": "2539:19:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "expression": {
                                "argumentTypes": null,
                                "id": 11553,
                                "name": "_tradeAccount",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 11536,
                                "src": "2576:13:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                                  "typeString": "struct Account.Info memory"
                                }
                              },
                              "id": 11554,
                              "isConstant": false,
                              "isLValue": true,
                              "isPure": false,
                              "lValueRequested": false,
                              "memberName": "number",
                              "nodeType": "MemberAccess",
                              "referencedDeclaration": 24850,
                              "src": "2576:20:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              }
                            }
                          ],
                          "expression": {
                            "argumentTypes": [
                              {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              },
                              {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              }
                            ],
                            "expression": {
                              "argumentTypes": null,
                              "expression": {
                                "argumentTypes": null,
                                "id": 11546,
                                "name": "_cache",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 11534,
                                "src": "2471:6:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                  "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                                }
                              },
                              "id": 11549,
                              "isConstant": false,
                              "isLValue": true,
                              "isPure": false,
                              "lValueRequested": false,
                              "memberName": "eventEmitterRegistry",
                              "nodeType": "MemberAccess",
                              "referencedDeclaration": 4592,
                              "src": "2471:27:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_contract$_IEventEmitterRegistry_$4498",
                                "typeString": "contract IEventEmitterRegistry"
                              }
                            },
                            "id": 11550,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": false,
                            "lValueRequested": false,
                            "memberName": "emitBorrowPositionOpen",
                            "nodeType": "MemberAccess",
                            "referencedDeclaration": 4459,
                            "src": "2471:50:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$",
                              "typeString": "function (address,uint256) external"
                            }
                          },
                          "id": 11555,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "kind": "functionCall",
                          "lValueRequested": false,
                          "names": [],
                          "nodeType": "FunctionCall",
                          "src": "2471:139:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_tuple$__$",
                            "typeString": "tuple()"
                          }
                        },
                        "id": 11556,
                        "nodeType": "ExpressionStatement",
                        "src": "2471:139:52"
                      }
                    ]
                  }
                }
              ]
            },
            "documentation": null,
            "id": 11560,
            "implemented": true,
            "kind": "function",
            "modifiers": [],
            "name": "logBeforeZapEvents",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 11539,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 11534,
                  "name": "_cache",
                  "nodeType": "VariableDeclaration",
                  "scope": 11560,
                  "src": "2195:61:52",
                  "stateVariable": false,
                  "storageLocation": "memory",
                  "typeDescriptions": {
                    "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                    "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache"
                  },
                  "typeName": {
                    "contractScope": null,
                    "id": 11533,
                    "name": "IGenericTraderProxyBase.GenericTraderProxyCache",
                    "nodeType": "UserDefinedTypeName",
                    "referencedDeclaration": 4607,
                    "src": "2195:47:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_storage_ptr",
                      "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 11536,
                  "name": "_tradeAccount",
                  "nodeType": "VariableDeclaration",
                  "scope": 11560,
                  "src": "2266:33:52",
                  "stateVariable": false,
                  "storageLocation": "memory",
                  "typeDescriptions": {
                    "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                    "typeString": "struct Account.Info"
                  },
                  "typeName": {
                    "contractScope": null,
                    "id": 11535,
                    "name": "Account.Info",
                    "nodeType": "UserDefinedTypeName",
                    "referencedDeclaration": 24851,
                    "src": "2266:12:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_struct$_Info_$24851_storage_ptr",
                      "typeString": "struct Account.Info"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 11538,
                  "name": "_eventType",
                  "nodeType": "VariableDeclaration",
                  "scope": 11560,
                  "src": "2309:50:52",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_enum$_EventEmissionType_$4627",
                    "typeString": "enum IGenericTraderProxyV1.EventEmissionType"
                  },
                  "typeName": {
                    "contractScope": null,
                    "id": 11537,
                    "name": "IGenericTraderProxyV1.EventEmissionType",
                    "nodeType": "UserDefinedTypeName",
                    "referencedDeclaration": 4627,
                    "src": "2309:39:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_enum$_EventEmissionType_$4627",
                      "typeString": "enum IGenericTraderProxyV1.EventEmissionType"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "2185:180:52"
            },
            "returnParameters": {
              "id": 11540,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "2373:0:52"
            },
            "scope": 11828,
            "src": "2158:469:52",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "public"
          },
          {
            "body": {
              "id": 11604,
              "nodeType": "Block",
              "src": "3032:456:52",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "expression": {
                          "argumentTypes": null,
                          "id": 11582,
                          "name": "_tradeAccount",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 11564,
                          "src": "3099:13:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                            "typeString": "struct Account.Info memory"
                          }
                        },
                        "id": 11583,
                        "isConstant": false,
                        "isLValue": true,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "owner",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": 24848,
                        "src": "3099:19:52",
                        "typeDescriptions": {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "expression": {
                          "argumentTypes": null,
                          "id": 11584,
                          "name": "_tradeAccount",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 11564,
                          "src": "3132:13:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                            "typeString": "struct Account.Info memory"
                          }
                        },
                        "id": 11585,
                        "isConstant": false,
                        "isLValue": true,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "number",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": 24850,
                        "src": "3132:20:52",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 11586,
                        "name": "_marketIdsPath",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 11567,
                        "src": "3166:14:52",
                        "typeDescriptions": {
                          "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                          "typeString": "uint256[] memory"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 11587,
                        "name": "_tradersPath",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 11570,
                        "src": "3194:12:52",
                        "typeDescriptions": {
                          "typeIdentifier": "t_array$_t_struct$_TraderParam_$4588_memory_$dyn_memory_ptr",
                          "typeString": "struct IGenericTraderProxyBase.TraderParam memory[] memory"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        },
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        },
                        {
                          "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                          "typeString": "uint256[] memory"
                        },
                        {
                          "typeIdentifier": "t_array$_t_struct$_TraderParam_$4588_memory_$dyn_memory_ptr",
                          "typeString": "struct IGenericTraderProxyBase.TraderParam memory[] memory"
                        }
                      ],
                      "expression": {
                        "argumentTypes": null,
                        "expression": {
                          "argumentTypes": null,
                          "id": 11577,
                          "name": "_cache",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 11562,
                          "src": "3042:6:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                            "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                          }
                        },
                        "id": 11580,
                        "isConstant": false,
                        "isLValue": true,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "eventEmitterRegistry",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": 4592,
                        "src": "3042:27:52",
                        "typeDescriptions": {
                          "typeIdentifier": "t_contract$_IEventEmitterRegistry_$4498",
                          "typeString": "contract IEventEmitterRegistry"
                        }
                      },
                      "id": 11581,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "emitZapExecuted",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 4452,
                      "src": "3042:43:52",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$_t_array$_t_uint256_$dyn_memory_ptr_$_t_array$_t_struct$_TraderParam_$4588_memory_$dyn_memory_ptr_$returns$__$",
                        "typeString": "function (address,uint256,uint256[] memory,struct IGenericTraderProxyBase.TraderParam memory[] memory) external"
                      }
                    },
                    "id": 11588,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "3042:174:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 11589,
                  "nodeType": "ExpressionStatement",
                  "src": "3042:174:52"
                },
                {
                  "condition": {
                    "argumentTypes": null,
                    "commonType": {
                      "typeIdentifier": "t_enum$_EventEmissionType_$4627",
                      "typeString": "enum IGenericTraderProxyV1.EventEmissionType"
                    },
                    "id": 11594,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftExpression": {
                      "argumentTypes": null,
                      "id": 11590,
                      "name": "_eventType",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 11574,
                      "src": "3231:10:52",
                      "typeDescriptions": {
                        "typeIdentifier": "t_enum$_EventEmissionType_$4627",
                        "typeString": "enum IGenericTraderProxyV1.EventEmissionType"
                      }
                    },
                    "nodeType": "BinaryOperation",
                    "operator": "==",
                    "rightExpression": {
                      "argumentTypes": null,
                      "expression": {
                        "argumentTypes": null,
                        "expression": {
                          "argumentTypes": null,
                          "id": 11591,
                          "name": "IGenericTraderProxyV1",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 4697,
                          "src": "3245:21:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_type$_t_contract$_IGenericTraderProxyV1_$4697_$",
                            "typeString": "type(contract IGenericTraderProxyV1)"
                          }
                        },
                        "id": 11592,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "EventEmissionType",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": 4627,
                        "src": "3245:39:52",
                        "typeDescriptions": {
                          "typeIdentifier": "t_type$_t_enum$_EventEmissionType_$4627_$",
                          "typeString": "type(enum IGenericTraderProxyV1.EventEmissionType)"
                        }
                      },
                      "id": 11593,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": true,
                      "lValueRequested": false,
                      "memberName": "MarginPosition",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": null,
                      "src": "3245:54:52",
                      "typeDescriptions": {
                        "typeIdentifier": "t_enum$_EventEmissionType_$4627",
                        "typeString": "enum IGenericTraderProxyV1.EventEmissionType"
                      }
                    },
                    "src": "3231:68:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "falseBody": null,
                  "id": 11603,
                  "nodeType": "IfStatement",
                  "src": "3227:255:52",
                  "trueBody": {
                    "id": 11602,
                    "nodeType": "Block",
                    "src": "3301:181:52",
                    "statements": [
                      {
                        "expression": {
                          "argumentTypes": null,
                          "arguments": [
                            {
                              "argumentTypes": null,
                              "id": 11596,
                              "name": "_cache",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 11562,
                              "src": "3356:6:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "id": 11597,
                              "name": "_tradeAccount",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 11564,
                              "src": "3380:13:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                                "typeString": "struct Account.Info memory"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "id": 11598,
                              "name": "_marketIdsPath",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 11567,
                              "src": "3411:14:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                                "typeString": "uint256[] memory"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "id": 11599,
                              "name": "_transferParam",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 11572,
                              "src": "3443:14:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_TransferCollateralParam_$4640_memory_ptr",
                                "typeString": "struct IGenericTraderProxyV1.TransferCollateralParam memory"
                              }
                            }
                          ],
                          "expression": {
                            "argumentTypes": [
                              {
                                "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                              },
                              {
                                "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                                "typeString": "struct Account.Info memory"
                              },
                              {
                                "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                                "typeString": "uint256[] memory"
                              },
                              {
                                "typeIdentifier": "t_struct$_TransferCollateralParam_$4640_memory_ptr",
                                "typeString": "struct IGenericTraderProxyV1.TransferCollateralParam memory"
                              }
                            ],
                            "id": 11595,
                            "name": "_logMarginPositionEvent",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 11827,
                            "src": "3315:23:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_function_internal_nonpayable$_t_struct$_GenericTraderProxyCache_$4607_memory_ptr_$_t_struct$_Info_$24851_memory_ptr_$_t_array$_t_uint256_$dyn_memory_ptr_$_t_struct$_TransferCollateralParam_$4640_memory_ptr_$returns$__$",
                              "typeString": "function (struct IGenericTraderProxyBase.GenericTraderProxyCache memory,struct Account.Info memory,uint256[] memory,struct IGenericTraderProxyV1.TransferCollateralParam memory)"
                            }
                          },
                          "id": 11600,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "kind": "functionCall",
                          "lValueRequested": false,
                          "names": [],
                          "nodeType": "FunctionCall",
                          "src": "3315:156:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_tuple$__$",
                            "typeString": "tuple()"
                          }
                        },
                        "id": 11601,
                        "nodeType": "ExpressionStatement",
                        "src": "3315:156:52"
                      }
                    ]
                  }
                }
              ]
            },
            "documentation": null,
            "id": 11605,
            "implemented": true,
            "kind": "function",
            "modifiers": [],
            "name": "logAfterZapEvents",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 11575,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 11562,
                  "name": "_cache",
                  "nodeType": "VariableDeclaration",
                  "scope": 11605,
                  "src": "2669:61:52",
                  "stateVariable": false,
                  "storageLocation": "memory",
                  "typeDescriptions": {
                    "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                    "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache"
                  },
                  "typeName": {
                    "contractScope": null,
                    "id": 11561,
                    "name": "IGenericTraderProxyBase.GenericTraderProxyCache",
                    "nodeType": "UserDefinedTypeName",
                    "referencedDeclaration": 4607,
                    "src": "2669:47:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_storage_ptr",
                      "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 11564,
                  "name": "_tradeAccount",
                  "nodeType": "VariableDeclaration",
                  "scope": 11605,
                  "src": "2740:33:52",
                  "stateVariable": false,
                  "storageLocation": "memory",
                  "typeDescriptions": {
                    "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                    "typeString": "struct Account.Info"
                  },
                  "typeName": {
                    "contractScope": null,
                    "id": 11563,
                    "name": "Account.Info",
                    "nodeType": "UserDefinedTypeName",
                    "referencedDeclaration": 24851,
                    "src": "2740:12:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_struct$_Info_$24851_storage_ptr",
                      "typeString": "struct Account.Info"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 11567,
                  "name": "_marketIdsPath",
                  "nodeType": "VariableDeclaration",
                  "scope": 11605,
                  "src": "2783:31:52",
                  "stateVariable": false,
                  "storageLocation": "memory",
                  "typeDescriptions": {
                    "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                    "typeString": "uint256[]"
                  },
                  "typeName": {
                    "baseType": {
                      "id": 11565,
                      "name": "uint256",
                      "nodeType": "ElementaryTypeName",
                      "src": "2783:7:52",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "id": 11566,
                    "length": null,
                    "nodeType": "ArrayTypeName",
                    "src": "2783:9:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_array$_t_uint256_$dyn_storage_ptr",
                      "typeString": "uint256[]"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 11570,
                  "name": "_tradersPath",
                  "nodeType": "VariableDeclaration",
                  "scope": 11605,
                  "src": "2824:57:52",
                  "stateVariable": false,
                  "storageLocation": "memory",
                  "typeDescriptions": {
                    "typeIdentifier": "t_array$_t_struct$_TraderParam_$4588_memory_$dyn_memory_ptr",
                    "typeString": "struct IGenericTraderProxyBase.TraderParam[]"
                  },
                  "typeName": {
                    "baseType": {
                      "contractScope": null,
                      "id": 11568,
                      "name": "IGenericTraderProxyBase.TraderParam",
                      "nodeType": "UserDefinedTypeName",
                      "referencedDeclaration": 4588,
                      "src": "2824:35:52",
                      "typeDescriptions": {
                        "typeIdentifier": "t_struct$_TraderParam_$4588_storage_ptr",
                        "typeString": "struct IGenericTraderProxyBase.TraderParam"
                      }
                    },
                    "id": 11569,
                    "length": null,
                    "nodeType": "ArrayTypeName",
                    "src": "2824:37:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_array$_t_struct$_TraderParam_$4588_storage_$dyn_storage_ptr",
                      "typeString": "struct IGenericTraderProxyBase.TraderParam[]"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 11572,
                  "name": "_transferParam",
                  "nodeType": "VariableDeclaration",
                  "scope": 11605,
                  "src": "2891:67:52",
                  "stateVariable": false,
                  "storageLocation": "memory",
                  "typeDescriptions": {
                    "typeIdentifier": "t_struct$_TransferCollateralParam_$4640_memory_ptr",
                    "typeString": "struct IGenericTraderProxyV1.TransferCollateralParam"
                  },
                  "typeName": {
                    "contractScope": null,
                    "id": 11571,
                    "name": "IGenericTraderProxyV1.TransferCollateralParam",
                    "nodeType": "UserDefinedTypeName",
                    "referencedDeclaration": 4640,
                    "src": "2891:45:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_struct$_TransferCollateralParam_$4640_storage_ptr",
                      "typeString": "struct IGenericTraderProxyV1.TransferCollateralParam"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 11574,
                  "name": "_eventType",
                  "nodeType": "VariableDeclaration",
                  "scope": 11605,
                  "src": "2968:50:52",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_enum$_EventEmissionType_$4627",
                    "typeString": "enum IGenericTraderProxyV1.EventEmissionType"
                  },
                  "typeName": {
                    "contractScope": null,
                    "id": 11573,
                    "name": "IGenericTraderProxyV1.EventEmissionType",
                    "nodeType": "UserDefinedTypeName",
                    "referencedDeclaration": 4627,
                    "src": "2968:39:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_enum$_EventEmissionType_$4627",
                      "typeString": "enum IGenericTraderProxyV1.EventEmissionType"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "2659:365:52"
            },
            "returnParameters": {
              "id": 11576,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "3032:0:52"
            },
            "scope": 11828,
            "src": "2633:855:52",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "public"
          },
          {
            "body": {
              "id": 11826,
              "nodeType": "Block",
              "src": "3766:3233:52",
              "statements": [
                {
                  "assignments": [
                    11620
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 11620,
                      "name": "inputBalanceUpdate",
                      "nodeType": "VariableDeclaration",
                      "scope": 11826,
                      "src": "3776:46:52",
                      "stateVariable": false,
                      "storageLocation": "memory",
                      "typeDescriptions": {
                        "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                        "typeString": "struct Events.BalanceUpdate"
                      },
                      "typeName": {
                        "contractScope": null,
                        "id": 11619,
                        "name": "Events.BalanceUpdate",
                        "nodeType": "UserDefinedTypeName",
                        "referencedDeclaration": 26624,
                        "src": "3776:20:52",
                        "typeDescriptions": {
                          "typeIdentifier": "t_struct$_BalanceUpdate_$26624_storage_ptr",
                          "typeString": "struct Events.BalanceUpdate"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 11621,
                  "initialValue": null,
                  "nodeType": "VariableDeclarationStatement",
                  "src": "3776:46:52"
                },
                {
                  "id": 11654,
                  "nodeType": "Block",
                  "src": "3870:455:52",
                  "statements": [
                    {
                      "assignments": [
                        11625
                      ],
                      "declarations": [
                        {
                          "constant": false,
                          "id": 11625,
                          "name": "inputBalanceWeiAfter",
                          "nodeType": "VariableDeclaration",
                          "scope": 11654,
                          "src": "3884:37:52",
                          "stateVariable": false,
                          "storageLocation": "memory",
                          "typeDescriptions": {
                            "typeIdentifier": "t_struct$_Wei_$31149_memory_ptr",
                            "typeString": "struct Types.Wei"
                          },
                          "typeName": {
                            "contractScope": null,
                            "id": 11624,
                            "name": "Types.Wei",
                            "nodeType": "UserDefinedTypeName",
                            "referencedDeclaration": 31149,
                            "src": "3884:9:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_struct$_Wei_$31149_storage_ptr",
                              "typeString": "struct Types.Wei"
                            }
                          },
                          "value": null,
                          "visibility": "internal"
                        }
                      ],
                      "id": 11634,
                      "initialValue": {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "id": 11629,
                            "name": "_tradeAccount",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 11609,
                            "src": "3977:13:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                              "typeString": "struct Account.Info memory"
                            }
                          },
                          {
                            "argumentTypes": null,
                            "baseExpression": {
                              "argumentTypes": null,
                              "id": 11630,
                              "name": "_marketIdsPath",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 11612,
                              "src": "4028:14:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                                "typeString": "uint256[] memory"
                              }
                            },
                            "id": 11632,
                            "indexExpression": {
                              "argumentTypes": null,
                              "hexValue": "30",
                              "id": 11631,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": true,
                              "kind": "number",
                              "lValueRequested": false,
                              "nodeType": "Literal",
                              "src": "4043:1:52",
                              "subdenomination": null,
                              "typeDescriptions": {
                                "typeIdentifier": "t_rational_0_by_1",
                                "typeString": "int_const 0"
                              },
                              "value": "0"
                            },
                            "isConstant": false,
                            "isLValue": true,
                            "isPure": false,
                            "lValueRequested": false,
                            "nodeType": "IndexAccess",
                            "src": "4028:17:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                              "typeString": "struct Account.Info memory"
                            },
                            {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          ],
                          "expression": {
                            "argumentTypes": null,
                            "expression": {
                              "argumentTypes": null,
                              "id": 11626,
                              "name": "_cache",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 11607,
                              "src": "3924:6:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                              }
                            },
                            "id": 11627,
                            "isConstant": false,
                            "isLValue": true,
                            "isPure": false,
                            "lValueRequested": false,
                            "memberName": "dolomiteMargin",
                            "nodeType": "MemberAccess",
                            "referencedDeclaration": 4590,
                            "src": "3924:21:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_contract$_IDolomiteMargin_$24693",
                              "typeString": "contract IDolomiteMargin"
                            }
                          },
                          "id": 11628,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "memberName": "getAccountWei",
                          "nodeType": "MemberAccess",
                          "referencedDeclaration": 24407,
                          "src": "3924:35:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_function_external_view$_t_struct$_Info_$24851_memory_ptr_$_t_uint256_$returns$_t_struct$_Wei_$31149_memory_ptr_$",
                            "typeString": "function (struct Account.Info memory,uint256) view external returns (struct Types.Wei memory)"
                          }
                        },
                        "id": 11633,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "functionCall",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "3924:135:52",
                        "typeDescriptions": {
                          "typeIdentifier": "t_struct$_Wei_$31149_memory_ptr",
                          "typeString": "struct Types.Wei memory"
                        }
                      },
                      "nodeType": "VariableDeclarationStatement",
                      "src": "3884:175:52"
                    },
                    {
                      "expression": {
                        "argumentTypes": null,
                        "id": 11652,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "leftHandSide": {
                          "argumentTypes": null,
                          "id": 11635,
                          "name": "inputBalanceUpdate",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 11620,
                          "src": "4073:18:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                            "typeString": "struct Events.BalanceUpdate memory"
                          }
                        },
                        "nodeType": "Assignment",
                        "operator": "=",
                        "rightHandSide": {
                          "argumentTypes": null,
                          "arguments": [
                            {
                              "argumentTypes": null,
                              "arguments": [
                                {
                                  "argumentTypes": null,
                                  "expression": {
                                    "argumentTypes": null,
                                    "id": 11640,
                                    "name": "_cache",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11607,
                                    "src": "4168:6:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                      "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                                    }
                                  },
                                  "id": 11641,
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "memberName": "inputBalanceWeiBeforeOperate",
                                  "nodeType": "MemberAccess",
                                  "referencedDeclaration": 4602,
                                  "src": "4168:35:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_struct$_Wei_$31149_memory",
                                    "typeString": "struct Types.Wei memory"
                                  }
                                }
                              ],
                              "expression": {
                                "argumentTypes": [
                                  {
                                    "typeIdentifier": "t_struct$_Wei_$31149_memory",
                                    "typeString": "struct Types.Wei memory"
                                  }
                                ],
                                "expression": {
                                  "argumentTypes": null,
                                  "id": 11638,
                                  "name": "inputBalanceWeiAfter",
                                  "nodeType": "Identifier",
                                  "overloadedDeclarations": [],
                                  "referencedDeclaration": 11625,
                                  "src": "4143:20:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_struct$_Wei_$31149_memory_ptr",
                                    "typeString": "struct Types.Wei memory"
                                  }
                                },
                                "id": 11639,
                                "isConstant": false,
                                "isLValue": true,
                                "isPure": false,
                                "lValueRequested": false,
                                "memberName": "sub",
                                "nodeType": "MemberAccess",
                                "referencedDeclaration": 31177,
                                "src": "4143:24:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_function_internal_pure$_t_struct$_Wei_$31149_memory_ptr_$_t_struct$_Wei_$31149_memory_ptr_$returns$_t_struct$_Wei_$31149_memory_ptr_$bound_to$_t_struct$_Wei_$31149_memory_ptr_$",
                                  "typeString": "function (struct Types.Wei memory,struct Types.Wei memory) pure returns (struct Types.Wei memory)"
                                }
                              },
                              "id": 11642,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "kind": "functionCall",
                              "lValueRequested": false,
                              "names": [],
                              "nodeType": "FunctionCall",
                              "src": "4143:61:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_Wei_$31149_memory_ptr",
                                "typeString": "struct Types.Wei memory"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "arguments": [
                                {
                                  "argumentTypes": null,
                                  "id": 11646,
                                  "name": "_tradeAccount",
                                  "nodeType": "Identifier",
                                  "overloadedDeclarations": [],
                                  "referencedDeclaration": 11609,
                                  "src": "4266:13:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                                    "typeString": "struct Account.Info memory"
                                  }
                                },
                                {
                                  "argumentTypes": null,
                                  "baseExpression": {
                                    "argumentTypes": null,
                                    "id": 11647,
                                    "name": "_marketIdsPath",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11612,
                                    "src": "4281:14:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                                      "typeString": "uint256[] memory"
                                    }
                                  },
                                  "id": 11649,
                                  "indexExpression": {
                                    "argumentTypes": null,
                                    "hexValue": "30",
                                    "id": 11648,
                                    "isConstant": false,
                                    "isLValue": false,
                                    "isPure": true,
                                    "kind": "number",
                                    "lValueRequested": false,
                                    "nodeType": "Literal",
                                    "src": "4296:1:52",
                                    "subdenomination": null,
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_rational_0_by_1",
                                      "typeString": "int_const 0"
                                    },
                                    "value": "0"
                                  },
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "nodeType": "IndexAccess",
                                  "src": "4281:17:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                }
                              ],
                              "expression": {
                                "argumentTypes": [
                                  {
                                    "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                                    "typeString": "struct Account.Info memory"
                                  },
                                  {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                ],
                                "expression": {
                                  "argumentTypes": null,
                                  "expression": {
                                    "argumentTypes": null,
                                    "id": 11643,
                                    "name": "_cache",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11607,
                                    "src": "4230:6:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                      "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                                    }
                                  },
                                  "id": 11644,
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "memberName": "dolomiteMargin",
                                  "nodeType": "MemberAccess",
                                  "referencedDeclaration": 4590,
                                  "src": "4230:21:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_contract$_IDolomiteMargin_$24693",
                                    "typeString": "contract IDolomiteMargin"
                                  }
                                },
                                "id": 11645,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": false,
                                "lValueRequested": false,
                                "memberName": "getAccountPar",
                                "nodeType": "MemberAccess",
                                "referencedDeclaration": 24398,
                                "src": "4230:35:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_function_external_view$_t_struct$_Info_$24851_memory_ptr_$_t_uint256_$returns$_t_struct$_Par_$30890_memory_ptr_$",
                                  "typeString": "function (struct Account.Info memory,uint256) view external returns (struct Types.Par memory)"
                                }
                              },
                              "id": 11650,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "kind": "functionCall",
                              "lValueRequested": false,
                              "names": [],
                              "nodeType": "FunctionCall",
                              "src": "4230:69:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_Par_$30890_memory_ptr",
                                "typeString": "struct Types.Par memory"
                              }
                            }
                          ],
                          "expression": {
                            "argumentTypes": [
                              {
                                "typeIdentifier": "t_struct$_Wei_$31149_memory_ptr",
                                "typeString": "struct Types.Wei memory"
                              },
                              {
                                "typeIdentifier": "t_struct$_Par_$30890_memory_ptr",
                                "typeString": "struct Types.Par memory"
                              }
                            ],
                            "expression": {
                              "argumentTypes": null,
                              "id": 11636,
                              "name": "Events",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 27153,
                              "src": "4094:6:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_type$_t_contract$_Events_$27153_$",
                                "typeString": "type(library Events)"
                              }
                            },
                            "id": 11637,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": false,
                            "lValueRequested": false,
                            "memberName": "BalanceUpdate",
                            "nodeType": "MemberAccess",
                            "referencedDeclaration": 26624,
                            "src": "4094:20:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_type$_t_struct$_BalanceUpdate_$26624_storage_ptr_$",
                              "typeString": "type(struct Events.BalanceUpdate storage pointer)"
                            }
                          },
                          "id": 11651,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "kind": "structConstructorCall",
                          "lValueRequested": false,
                          "names": [
                            "deltaWei",
                            "newPar"
                          ],
                          "nodeType": "FunctionCall",
                          "src": "4094:220:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory",
                            "typeString": "struct Events.BalanceUpdate memory"
                          }
                        },
                        "src": "4073:241:52",
                        "typeDescriptions": {
                          "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                          "typeString": "struct Events.BalanceUpdate memory"
                        }
                      },
                      "id": 11653,
                      "nodeType": "ExpressionStatement",
                      "src": "4073:241:52"
                    }
                  ]
                },
                {
                  "assignments": [
                    11658
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 11658,
                      "name": "outputBalanceUpdate",
                      "nodeType": "VariableDeclaration",
                      "scope": 11826,
                      "src": "4372:47:52",
                      "stateVariable": false,
                      "storageLocation": "memory",
                      "typeDescriptions": {
                        "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                        "typeString": "struct Events.BalanceUpdate"
                      },
                      "typeName": {
                        "contractScope": null,
                        "id": 11657,
                        "name": "Events.BalanceUpdate",
                        "nodeType": "UserDefinedTypeName",
                        "referencedDeclaration": 26624,
                        "src": "4372:20:52",
                        "typeDescriptions": {
                          "typeIdentifier": "t_struct$_BalanceUpdate_$26624_storage_ptr",
                          "typeString": "struct Events.BalanceUpdate"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 11659,
                  "initialValue": null,
                  "nodeType": "VariableDeclarationStatement",
                  "src": "4372:47:52"
                },
                {
                  "id": 11698,
                  "nodeType": "Block",
                  "src": "4467:508:52",
                  "statements": [
                    {
                      "assignments": [
                        11663
                      ],
                      "declarations": [
                        {
                          "constant": false,
                          "id": 11663,
                          "name": "outputBalanceWeiAfter",
                          "nodeType": "VariableDeclaration",
                          "scope": 11698,
                          "src": "4481:38:52",
                          "stateVariable": false,
                          "storageLocation": "memory",
                          "typeDescriptions": {
                            "typeIdentifier": "t_struct$_Wei_$31149_memory_ptr",
                            "typeString": "struct Types.Wei"
                          },
                          "typeName": {
                            "contractScope": null,
                            "id": 11662,
                            "name": "Types.Wei",
                            "nodeType": "UserDefinedTypeName",
                            "referencedDeclaration": 31149,
                            "src": "4481:9:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_struct$_Wei_$31149_storage_ptr",
                              "typeString": "struct Types.Wei"
                            }
                          },
                          "value": null,
                          "visibility": "internal"
                        }
                      ],
                      "id": 11675,
                      "initialValue": {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "id": 11667,
                            "name": "_tradeAccount",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 11609,
                            "src": "4575:13:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                              "typeString": "struct Account.Info memory"
                            }
                          },
                          {
                            "argumentTypes": null,
                            "baseExpression": {
                              "argumentTypes": null,
                              "id": 11668,
                              "name": "_marketIdsPath",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 11612,
                              "src": "4627:14:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                                "typeString": "uint256[] memory"
                              }
                            },
                            "id": 11673,
                            "indexExpression": {
                              "argumentTypes": null,
                              "commonType": {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              },
                              "id": 11672,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "lValueRequested": false,
                              "leftExpression": {
                                "argumentTypes": null,
                                "expression": {
                                  "argumentTypes": null,
                                  "id": 11669,
                                  "name": "_marketIdsPath",
                                  "nodeType": "Identifier",
                                  "overloadedDeclarations": [],
                                  "referencedDeclaration": 11612,
                                  "src": "4642:14:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                                    "typeString": "uint256[] memory"
                                  }
                                },
                                "id": 11670,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": false,
                                "lValueRequested": false,
                                "memberName": "length",
                                "nodeType": "MemberAccess",
                                "referencedDeclaration": null,
                                "src": "4642:21:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_uint256",
                                  "typeString": "uint256"
                                }
                              },
                              "nodeType": "BinaryOperation",
                              "operator": "-",
                              "rightExpression": {
                                "argumentTypes": null,
                                "hexValue": "31",
                                "id": 11671,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": true,
                                "kind": "number",
                                "lValueRequested": false,
                                "nodeType": "Literal",
                                "src": "4666:1:52",
                                "subdenomination": null,
                                "typeDescriptions": {
                                  "typeIdentifier": "t_rational_1_by_1",
                                  "typeString": "int_const 1"
                                },
                                "value": "1"
                              },
                              "src": "4642:25:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              }
                            },
                            "isConstant": false,
                            "isLValue": true,
                            "isPure": false,
                            "lValueRequested": false,
                            "nodeType": "IndexAccess",
                            "src": "4627:41:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                              "typeString": "struct Account.Info memory"
                            },
                            {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          ],
                          "expression": {
                            "argumentTypes": null,
                            "expression": {
                              "argumentTypes": null,
                              "id": 11664,
                              "name": "_cache",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 11607,
                              "src": "4522:6:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                              }
                            },
                            "id": 11665,
                            "isConstant": false,
                            "isLValue": true,
                            "isPure": false,
                            "lValueRequested": false,
                            "memberName": "dolomiteMargin",
                            "nodeType": "MemberAccess",
                            "referencedDeclaration": 4590,
                            "src": "4522:21:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_contract$_IDolomiteMargin_$24693",
                              "typeString": "contract IDolomiteMargin"
                            }
                          },
                          "id": 11666,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "memberName": "getAccountWei",
                          "nodeType": "MemberAccess",
                          "referencedDeclaration": 24407,
                          "src": "4522:35:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_function_external_view$_t_struct$_Info_$24851_memory_ptr_$_t_uint256_$returns$_t_struct$_Wei_$31149_memory_ptr_$",
                            "typeString": "function (struct Account.Info memory,uint256) view external returns (struct Types.Wei memory)"
                          }
                        },
                        "id": 11674,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "functionCall",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "4522:160:52",
                        "typeDescriptions": {
                          "typeIdentifier": "t_struct$_Wei_$31149_memory_ptr",
                          "typeString": "struct Types.Wei memory"
                        }
                      },
                      "nodeType": "VariableDeclarationStatement",
                      "src": "4481:201:52"
                    },
                    {
                      "expression": {
                        "argumentTypes": null,
                        "id": 11696,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "leftHandSide": {
                          "argumentTypes": null,
                          "id": 11676,
                          "name": "outputBalanceUpdate",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 11658,
                          "src": "4696:19:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                            "typeString": "struct Events.BalanceUpdate memory"
                          }
                        },
                        "nodeType": "Assignment",
                        "operator": "=",
                        "rightHandSide": {
                          "argumentTypes": null,
                          "arguments": [
                            {
                              "argumentTypes": null,
                              "arguments": [
                                {
                                  "argumentTypes": null,
                                  "expression": {
                                    "argumentTypes": null,
                                    "id": 11681,
                                    "name": "_cache",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11607,
                                    "src": "4793:6:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                      "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                                    }
                                  },
                                  "id": 11682,
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "memberName": "outputBalanceWeiBeforeOperate",
                                  "nodeType": "MemberAccess",
                                  "referencedDeclaration": 4604,
                                  "src": "4793:36:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_struct$_Wei_$31149_memory",
                                    "typeString": "struct Types.Wei memory"
                                  }
                                }
                              ],
                              "expression": {
                                "argumentTypes": [
                                  {
                                    "typeIdentifier": "t_struct$_Wei_$31149_memory",
                                    "typeString": "struct Types.Wei memory"
                                  }
                                ],
                                "expression": {
                                  "argumentTypes": null,
                                  "id": 11679,
                                  "name": "outputBalanceWeiAfter",
                                  "nodeType": "Identifier",
                                  "overloadedDeclarations": [],
                                  "referencedDeclaration": 11663,
                                  "src": "4767:21:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_struct$_Wei_$31149_memory_ptr",
                                    "typeString": "struct Types.Wei memory"
                                  }
                                },
                                "id": 11680,
                                "isConstant": false,
                                "isLValue": true,
                                "isPure": false,
                                "lValueRequested": false,
                                "memberName": "sub",
                                "nodeType": "MemberAccess",
                                "referencedDeclaration": 31177,
                                "src": "4767:25:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_function_internal_pure$_t_struct$_Wei_$31149_memory_ptr_$_t_struct$_Wei_$31149_memory_ptr_$returns$_t_struct$_Wei_$31149_memory_ptr_$bound_to$_t_struct$_Wei_$31149_memory_ptr_$",
                                  "typeString": "function (struct Types.Wei memory,struct Types.Wei memory) pure returns (struct Types.Wei memory)"
                                }
                              },
                              "id": 11683,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "kind": "functionCall",
                              "lValueRequested": false,
                              "names": [],
                              "nodeType": "FunctionCall",
                              "src": "4767:63:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_Wei_$31149_memory_ptr",
                                "typeString": "struct Types.Wei memory"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "arguments": [
                                {
                                  "argumentTypes": null,
                                  "id": 11687,
                                  "name": "_tradeAccount",
                                  "nodeType": "Identifier",
                                  "overloadedDeclarations": [],
                                  "referencedDeclaration": 11609,
                                  "src": "4892:13:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                                    "typeString": "struct Account.Info memory"
                                  }
                                },
                                {
                                  "argumentTypes": null,
                                  "baseExpression": {
                                    "argumentTypes": null,
                                    "id": 11688,
                                    "name": "_marketIdsPath",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11612,
                                    "src": "4907:14:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                                      "typeString": "uint256[] memory"
                                    }
                                  },
                                  "id": 11693,
                                  "indexExpression": {
                                    "argumentTypes": null,
                                    "commonType": {
                                      "typeIdentifier": "t_uint256",
                                      "typeString": "uint256"
                                    },
                                    "id": 11692,
                                    "isConstant": false,
                                    "isLValue": false,
                                    "isPure": false,
                                    "lValueRequested": false,
                                    "leftExpression": {
                                      "argumentTypes": null,
                                      "expression": {
                                        "argumentTypes": null,
                                        "id": 11689,
                                        "name": "_marketIdsPath",
                                        "nodeType": "Identifier",
                                        "overloadedDeclarations": [],
                                        "referencedDeclaration": 11612,
                                        "src": "4922:14:52",
                                        "typeDescriptions": {
                                          "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                                          "typeString": "uint256[] memory"
                                        }
                                      },
                                      "id": 11690,
                                      "isConstant": false,
                                      "isLValue": false,
                                      "isPure": false,
                                      "lValueRequested": false,
                                      "memberName": "length",
                                      "nodeType": "MemberAccess",
                                      "referencedDeclaration": null,
                                      "src": "4922:21:52",
                                      "typeDescriptions": {
                                        "typeIdentifier": "t_uint256",
                                        "typeString": "uint256"
                                      }
                                    },
                                    "nodeType": "BinaryOperation",
                                    "operator": "-",
                                    "rightExpression": {
                                      "argumentTypes": null,
                                      "hexValue": "31",
                                      "id": 11691,
                                      "isConstant": false,
                                      "isLValue": false,
                                      "isPure": true,
                                      "kind": "number",
                                      "lValueRequested": false,
                                      "nodeType": "Literal",
                                      "src": "4946:1:52",
                                      "subdenomination": null,
                                      "typeDescriptions": {
                                        "typeIdentifier": "t_rational_1_by_1",
                                        "typeString": "int_const 1"
                                      },
                                      "value": "1"
                                    },
                                    "src": "4922:25:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_uint256",
                                      "typeString": "uint256"
                                    }
                                  },
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "nodeType": "IndexAccess",
                                  "src": "4907:41:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                }
                              ],
                              "expression": {
                                "argumentTypes": [
                                  {
                                    "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                                    "typeString": "struct Account.Info memory"
                                  },
                                  {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                ],
                                "expression": {
                                  "argumentTypes": null,
                                  "expression": {
                                    "argumentTypes": null,
                                    "id": 11684,
                                    "name": "_cache",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11607,
                                    "src": "4856:6:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                      "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                                    }
                                  },
                                  "id": 11685,
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "memberName": "dolomiteMargin",
                                  "nodeType": "MemberAccess",
                                  "referencedDeclaration": 4590,
                                  "src": "4856:21:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_contract$_IDolomiteMargin_$24693",
                                    "typeString": "contract IDolomiteMargin"
                                  }
                                },
                                "id": 11686,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": false,
                                "lValueRequested": false,
                                "memberName": "getAccountPar",
                                "nodeType": "MemberAccess",
                                "referencedDeclaration": 24398,
                                "src": "4856:35:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_function_external_view$_t_struct$_Info_$24851_memory_ptr_$_t_uint256_$returns$_t_struct$_Par_$30890_memory_ptr_$",
                                  "typeString": "function (struct Account.Info memory,uint256) view external returns (struct Types.Par memory)"
                                }
                              },
                              "id": 11694,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "kind": "functionCall",
                              "lValueRequested": false,
                              "names": [],
                              "nodeType": "FunctionCall",
                              "src": "4856:93:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_Par_$30890_memory_ptr",
                                "typeString": "struct Types.Par memory"
                              }
                            }
                          ],
                          "expression": {
                            "argumentTypes": [
                              {
                                "typeIdentifier": "t_struct$_Wei_$31149_memory_ptr",
                                "typeString": "struct Types.Wei memory"
                              },
                              {
                                "typeIdentifier": "t_struct$_Par_$30890_memory_ptr",
                                "typeString": "struct Types.Par memory"
                              }
                            ],
                            "expression": {
                              "argumentTypes": null,
                              "id": 11677,
                              "name": "Events",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 27153,
                              "src": "4718:6:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_type$_t_contract$_Events_$27153_$",
                                "typeString": "type(library Events)"
                              }
                            },
                            "id": 11678,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": false,
                            "lValueRequested": false,
                            "memberName": "BalanceUpdate",
                            "nodeType": "MemberAccess",
                            "referencedDeclaration": 26624,
                            "src": "4718:20:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_type$_t_struct$_BalanceUpdate_$26624_storage_ptr_$",
                              "typeString": "type(struct Events.BalanceUpdate storage pointer)"
                            }
                          },
                          "id": 11695,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "kind": "structConstructorCall",
                          "lValueRequested": false,
                          "names": [
                            "deltaWei",
                            "newPar"
                          ],
                          "nodeType": "FunctionCall",
                          "src": "4718:246:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory",
                            "typeString": "struct Events.BalanceUpdate memory"
                          }
                        },
                        "src": "4696:268:52",
                        "typeDescriptions": {
                          "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                          "typeString": "struct Events.BalanceUpdate memory"
                        }
                      },
                      "id": 11697,
                      "nodeType": "ExpressionStatement",
                      "src": "4696:268:52"
                    }
                  ]
                },
                {
                  "assignments": [
                    11702
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 11702,
                      "name": "marginBalanceUpdate",
                      "nodeType": "VariableDeclaration",
                      "scope": 11826,
                      "src": "5022:47:52",
                      "stateVariable": false,
                      "storageLocation": "memory",
                      "typeDescriptions": {
                        "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                        "typeString": "struct Events.BalanceUpdate"
                      },
                      "typeName": {
                        "contractScope": null,
                        "id": 11701,
                        "name": "Events.BalanceUpdate",
                        "nodeType": "UserDefinedTypeName",
                        "referencedDeclaration": 26624,
                        "src": "5022:20:52",
                        "typeDescriptions": {
                          "typeIdentifier": "t_struct$_BalanceUpdate_$26624_storage_ptr",
                          "typeString": "struct Events.BalanceUpdate"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 11703,
                  "initialValue": null,
                  "nodeType": "VariableDeclarationStatement",
                  "src": "5022:47:52"
                },
                {
                  "id": 11740,
                  "nodeType": "Block",
                  "src": "5117:555:52",
                  "statements": [
                    {
                      "assignments": [
                        11707
                      ],
                      "declarations": [
                        {
                          "constant": false,
                          "id": 11707,
                          "name": "marginBalanceWeiAfter",
                          "nodeType": "VariableDeclaration",
                          "scope": 11740,
                          "src": "5131:38:52",
                          "stateVariable": false,
                          "storageLocation": "memory",
                          "typeDescriptions": {
                            "typeIdentifier": "t_struct$_Wei_$31149_memory_ptr",
                            "typeString": "struct Types.Wei"
                          },
                          "typeName": {
                            "contractScope": null,
                            "id": 11706,
                            "name": "Types.Wei",
                            "nodeType": "UserDefinedTypeName",
                            "referencedDeclaration": 31149,
                            "src": "5131:9:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_struct$_Wei_$31149_storage_ptr",
                              "typeString": "struct Types.Wei"
                            }
                          },
                          "value": null,
                          "visibility": "internal"
                        }
                      ],
                      "id": 11718,
                      "initialValue": {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "id": 11711,
                            "name": "_tradeAccount",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 11609,
                            "src": "5225:13:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                              "typeString": "struct Account.Info memory"
                            }
                          },
                          {
                            "argumentTypes": null,
                            "expression": {
                              "argumentTypes": null,
                              "baseExpression": {
                                "argumentTypes": null,
                                "expression": {
                                  "argumentTypes": null,
                                  "id": 11712,
                                  "name": "_param",
                                  "nodeType": "Identifier",
                                  "overloadedDeclarations": [],
                                  "referencedDeclaration": 11614,
                                  "src": "5278:6:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_struct$_TransferCollateralParam_$4640_memory_ptr",
                                    "typeString": "struct IGenericTraderProxyV1.TransferCollateralParam memory"
                                  }
                                },
                                "id": 11713,
                                "isConstant": false,
                                "isLValue": true,
                                "isPure": false,
                                "lValueRequested": false,
                                "memberName": "transferAmounts",
                                "nodeType": "MemberAccess",
                                "referencedDeclaration": 4639,
                                "src": "5278:22:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_array$_t_struct$_TransferAmount_$4632_memory_$dyn_memory",
                                  "typeString": "struct IGenericTraderProxyV1.TransferAmount memory[] memory"
                                }
                              },
                              "id": 11715,
                              "indexExpression": {
                                "argumentTypes": null,
                                "hexValue": "30",
                                "id": 11714,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": true,
                                "kind": "number",
                                "lValueRequested": false,
                                "nodeType": "Literal",
                                "src": "5301:1:52",
                                "subdenomination": null,
                                "typeDescriptions": {
                                  "typeIdentifier": "t_rational_0_by_1",
                                  "typeString": "int_const 0"
                                },
                                "value": "0"
                              },
                              "isConstant": false,
                              "isLValue": true,
                              "isPure": false,
                              "lValueRequested": false,
                              "nodeType": "IndexAccess",
                              "src": "5278:25:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_TransferAmount_$4632_memory",
                                "typeString": "struct IGenericTraderProxyV1.TransferAmount memory"
                              }
                            },
                            "id": 11716,
                            "isConstant": false,
                            "isLValue": true,
                            "isPure": false,
                            "lValueRequested": false,
                            "memberName": "marketId",
                            "nodeType": "MemberAccess",
                            "referencedDeclaration": 4629,
                            "src": "5278:34:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                              "typeString": "struct Account.Info memory"
                            },
                            {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          ],
                          "expression": {
                            "argumentTypes": null,
                            "expression": {
                              "argumentTypes": null,
                              "id": 11708,
                              "name": "_cache",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 11607,
                              "src": "5172:6:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                              }
                            },
                            "id": 11709,
                            "isConstant": false,
                            "isLValue": true,
                            "isPure": false,
                            "lValueRequested": false,
                            "memberName": "dolomiteMargin",
                            "nodeType": "MemberAccess",
                            "referencedDeclaration": 4590,
                            "src": "5172:21:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_contract$_IDolomiteMargin_$24693",
                              "typeString": "contract IDolomiteMargin"
                            }
                          },
                          "id": 11710,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "memberName": "getAccountWei",
                          "nodeType": "MemberAccess",
                          "referencedDeclaration": 24407,
                          "src": "5172:35:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_function_external_view$_t_struct$_Info_$24851_memory_ptr_$_t_uint256_$returns$_t_struct$_Wei_$31149_memory_ptr_$",
                            "typeString": "function (struct Account.Info memory,uint256) view external returns (struct Types.Wei memory)"
                          }
                        },
                        "id": 11717,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "functionCall",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "5172:154:52",
                        "typeDescriptions": {
                          "typeIdentifier": "t_struct$_Wei_$31149_memory_ptr",
                          "typeString": "struct Types.Wei memory"
                        }
                      },
                      "nodeType": "VariableDeclarationStatement",
                      "src": "5131:195:52"
                    },
                    {
                      "expression": {
                        "argumentTypes": null,
                        "id": 11738,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "leftHandSide": {
                          "argumentTypes": null,
                          "id": 11719,
                          "name": "marginBalanceUpdate",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 11702,
                          "src": "5340:19:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                            "typeString": "struct Events.BalanceUpdate memory"
                          }
                        },
                        "nodeType": "Assignment",
                        "operator": "=",
                        "rightHandSide": {
                          "argumentTypes": null,
                          "arguments": [
                            {
                              "argumentTypes": null,
                              "arguments": [
                                {
                                  "argumentTypes": null,
                                  "expression": {
                                    "argumentTypes": null,
                                    "id": 11724,
                                    "name": "_cache",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11607,
                                    "src": "5437:6:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                      "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                                    }
                                  },
                                  "id": 11725,
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "memberName": "transferBalanceWeiBeforeOperate",
                                  "nodeType": "MemberAccess",
                                  "referencedDeclaration": 4606,
                                  "src": "5437:38:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_struct$_Wei_$31149_memory",
                                    "typeString": "struct Types.Wei memory"
                                  }
                                }
                              ],
                              "expression": {
                                "argumentTypes": [
                                  {
                                    "typeIdentifier": "t_struct$_Wei_$31149_memory",
                                    "typeString": "struct Types.Wei memory"
                                  }
                                ],
                                "expression": {
                                  "argumentTypes": null,
                                  "id": 11722,
                                  "name": "marginBalanceWeiAfter",
                                  "nodeType": "Identifier",
                                  "overloadedDeclarations": [],
                                  "referencedDeclaration": 11707,
                                  "src": "5411:21:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_struct$_Wei_$31149_memory_ptr",
                                    "typeString": "struct Types.Wei memory"
                                  }
                                },
                                "id": 11723,
                                "isConstant": false,
                                "isLValue": true,
                                "isPure": false,
                                "lValueRequested": false,
                                "memberName": "sub",
                                "nodeType": "MemberAccess",
                                "referencedDeclaration": 31177,
                                "src": "5411:25:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_function_internal_pure$_t_struct$_Wei_$31149_memory_ptr_$_t_struct$_Wei_$31149_memory_ptr_$returns$_t_struct$_Wei_$31149_memory_ptr_$bound_to$_t_struct$_Wei_$31149_memory_ptr_$",
                                  "typeString": "function (struct Types.Wei memory,struct Types.Wei memory) pure returns (struct Types.Wei memory)"
                                }
                              },
                              "id": 11726,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "kind": "functionCall",
                              "lValueRequested": false,
                              "names": [],
                              "nodeType": "FunctionCall",
                              "src": "5411:65:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_Wei_$31149_memory_ptr",
                                "typeString": "struct Types.Wei memory"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "arguments": [
                                {
                                  "argumentTypes": null,
                                  "id": 11730,
                                  "name": "_tradeAccount",
                                  "nodeType": "Identifier",
                                  "overloadedDeclarations": [],
                                  "referencedDeclaration": 11609,
                                  "src": "5559:13:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                                    "typeString": "struct Account.Info memory"
                                  }
                                },
                                {
                                  "argumentTypes": null,
                                  "expression": {
                                    "argumentTypes": null,
                                    "baseExpression": {
                                      "argumentTypes": null,
                                      "expression": {
                                        "argumentTypes": null,
                                        "id": 11731,
                                        "name": "_param",
                                        "nodeType": "Identifier",
                                        "overloadedDeclarations": [],
                                        "referencedDeclaration": 11614,
                                        "src": "5594:6:52",
                                        "typeDescriptions": {
                                          "typeIdentifier": "t_struct$_TransferCollateralParam_$4640_memory_ptr",
                                          "typeString": "struct IGenericTraderProxyV1.TransferCollateralParam memory"
                                        }
                                      },
                                      "id": 11732,
                                      "isConstant": false,
                                      "isLValue": true,
                                      "isPure": false,
                                      "lValueRequested": false,
                                      "memberName": "transferAmounts",
                                      "nodeType": "MemberAccess",
                                      "referencedDeclaration": 4639,
                                      "src": "5594:22:52",
                                      "typeDescriptions": {
                                        "typeIdentifier": "t_array$_t_struct$_TransferAmount_$4632_memory_$dyn_memory",
                                        "typeString": "struct IGenericTraderProxyV1.TransferAmount memory[] memory"
                                      }
                                    },
                                    "id": 11734,
                                    "indexExpression": {
                                      "argumentTypes": null,
                                      "hexValue": "30",
                                      "id": 11733,
                                      "isConstant": false,
                                      "isLValue": false,
                                      "isPure": true,
                                      "kind": "number",
                                      "lValueRequested": false,
                                      "nodeType": "Literal",
                                      "src": "5617:1:52",
                                      "subdenomination": null,
                                      "typeDescriptions": {
                                        "typeIdentifier": "t_rational_0_by_1",
                                        "typeString": "int_const 0"
                                      },
                                      "value": "0"
                                    },
                                    "isConstant": false,
                                    "isLValue": true,
                                    "isPure": false,
                                    "lValueRequested": false,
                                    "nodeType": "IndexAccess",
                                    "src": "5594:25:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_struct$_TransferAmount_$4632_memory",
                                      "typeString": "struct IGenericTraderProxyV1.TransferAmount memory"
                                    }
                                  },
                                  "id": 11735,
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "memberName": "marketId",
                                  "nodeType": "MemberAccess",
                                  "referencedDeclaration": 4629,
                                  "src": "5594:34:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                }
                              ],
                              "expression": {
                                "argumentTypes": [
                                  {
                                    "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                                    "typeString": "struct Account.Info memory"
                                  },
                                  {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                ],
                                "expression": {
                                  "argumentTypes": null,
                                  "expression": {
                                    "argumentTypes": null,
                                    "id": 11727,
                                    "name": "_cache",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11607,
                                    "src": "5502:6:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                      "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                                    }
                                  },
                                  "id": 11728,
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "memberName": "dolomiteMargin",
                                  "nodeType": "MemberAccess",
                                  "referencedDeclaration": 4590,
                                  "src": "5502:21:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_contract$_IDolomiteMargin_$24693",
                                    "typeString": "contract IDolomiteMargin"
                                  }
                                },
                                "id": 11729,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": false,
                                "lValueRequested": false,
                                "memberName": "getAccountPar",
                                "nodeType": "MemberAccess",
                                "referencedDeclaration": 24398,
                                "src": "5502:35:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_function_external_view$_t_struct$_Info_$24851_memory_ptr_$_t_uint256_$returns$_t_struct$_Par_$30890_memory_ptr_$",
                                  "typeString": "function (struct Account.Info memory,uint256) view external returns (struct Types.Par memory)"
                                }
                              },
                              "id": 11736,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "kind": "functionCall",
                              "lValueRequested": false,
                              "names": [],
                              "nodeType": "FunctionCall",
                              "src": "5502:144:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_Par_$30890_memory_ptr",
                                "typeString": "struct Types.Par memory"
                              }
                            }
                          ],
                          "expression": {
                            "argumentTypes": [
                              {
                                "typeIdentifier": "t_struct$_Wei_$31149_memory_ptr",
                                "typeString": "struct Types.Wei memory"
                              },
                              {
                                "typeIdentifier": "t_struct$_Par_$30890_memory_ptr",
                                "typeString": "struct Types.Par memory"
                              }
                            ],
                            "expression": {
                              "argumentTypes": null,
                              "id": 11720,
                              "name": "Events",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 27153,
                              "src": "5362:6:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_type$_t_contract$_Events_$27153_$",
                                "typeString": "type(library Events)"
                              }
                            },
                            "id": 11721,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": false,
                            "lValueRequested": false,
                            "memberName": "BalanceUpdate",
                            "nodeType": "MemberAccess",
                            "referencedDeclaration": 26624,
                            "src": "5362:20:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_type$_t_struct$_BalanceUpdate_$26624_storage_ptr_$",
                              "typeString": "type(struct Events.BalanceUpdate storage pointer)"
                            }
                          },
                          "id": 11737,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "kind": "structConstructorCall",
                          "lValueRequested": false,
                          "names": [
                            "deltaWei",
                            "newPar"
                          ],
                          "nodeType": "FunctionCall",
                          "src": "5362:299:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory",
                            "typeString": "struct Events.BalanceUpdate memory"
                          }
                        },
                        "src": "5340:321:52",
                        "typeDescriptions": {
                          "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                          "typeString": "struct Events.BalanceUpdate memory"
                        }
                      },
                      "id": 11739,
                      "nodeType": "ExpressionStatement",
                      "src": "5340:321:52"
                    }
                  ]
                },
                {
                  "condition": {
                    "argumentTypes": null,
                    "expression": {
                      "argumentTypes": null,
                      "id": 11741,
                      "name": "_cache",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 11607,
                      "src": "5723:6:52",
                      "typeDescriptions": {
                        "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                        "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                      }
                    },
                    "id": 11742,
                    "isConstant": false,
                    "isLValue": true,
                    "isPure": false,
                    "lValueRequested": false,
                    "memberName": "isMarginDeposit",
                    "nodeType": "MemberAccess",
                    "referencedDeclaration": 4594,
                    "src": "5723:22:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "falseBody": {
                    "id": 11824,
                    "nodeType": "Block",
                    "src": "6371:622:52",
                    "statements": [
                      {
                        "expression": {
                          "argumentTypes": null,
                          "arguments": [
                            {
                              "argumentTypes": null,
                              "expression": {
                                "argumentTypes": null,
                                "id": 11789,
                                "name": "_tradeAccount",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 11609,
                                "src": "6454:13:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                                  "typeString": "struct Account.Info memory"
                                }
                              },
                              "id": 11790,
                              "isConstant": false,
                              "isLValue": true,
                              "isPure": false,
                              "lValueRequested": false,
                              "memberName": "owner",
                              "nodeType": "MemberAccess",
                              "referencedDeclaration": 24848,
                              "src": "6454:19:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "expression": {
                                "argumentTypes": null,
                                "id": 11791,
                                "name": "_tradeAccount",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 11609,
                                "src": "6491:13:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                                  "typeString": "struct Account.Info memory"
                                }
                              },
                              "id": 11792,
                              "isConstant": false,
                              "isLValue": true,
                              "isPure": false,
                              "lValueRequested": false,
                              "memberName": "number",
                              "nodeType": "MemberAccess",
                              "referencedDeclaration": 24850,
                              "src": "6491:20:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "arguments": [
                                {
                                  "argumentTypes": null,
                                  "baseExpression": {
                                    "argumentTypes": null,
                                    "id": 11796,
                                    "name": "_marketIdsPath",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11612,
                                    "src": "6593:14:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                                      "typeString": "uint256[] memory"
                                    }
                                  },
                                  "id": 11798,
                                  "indexExpression": {
                                    "argumentTypes": null,
                                    "hexValue": "30",
                                    "id": 11797,
                                    "isConstant": false,
                                    "isLValue": false,
                                    "isPure": true,
                                    "kind": "number",
                                    "lValueRequested": false,
                                    "nodeType": "Literal",
                                    "src": "6608:1:52",
                                    "subdenomination": null,
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_rational_0_by_1",
                                      "typeString": "int_const 0"
                                    },
                                    "value": "0"
                                  },
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "nodeType": "IndexAccess",
                                  "src": "6593:17:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                }
                              ],
                              "expression": {
                                "argumentTypes": [
                                  {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                ],
                                "expression": {
                                  "argumentTypes": null,
                                  "expression": {
                                    "argumentTypes": null,
                                    "id": 11793,
                                    "name": "_cache",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11607,
                                    "src": "6549:6:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                      "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                                    }
                                  },
                                  "id": 11794,
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "memberName": "dolomiteMargin",
                                  "nodeType": "MemberAccess",
                                  "referencedDeclaration": 4590,
                                  "src": "6549:21:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_contract$_IDolomiteMargin_$24693",
                                    "typeString": "contract IDolomiteMargin"
                                  }
                                },
                                "id": 11795,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": false,
                                "lValueRequested": false,
                                "memberName": "getMarketTokenAddress",
                                "nodeType": "MemberAccess",
                                "referencedDeclaration": 24229,
                                "src": "6549:43:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_function_external_view$_t_uint256_$returns$_t_address_$",
                                  "typeString": "function (uint256) view external returns (address)"
                                }
                              },
                              "id": 11799,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "kind": "functionCall",
                              "lValueRequested": false,
                              "names": [],
                              "nodeType": "FunctionCall",
                              "src": "6549:62:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "arguments": [
                                {
                                  "argumentTypes": null,
                                  "baseExpression": {
                                    "argumentTypes": null,
                                    "id": 11803,
                                    "name": "_marketIdsPath",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11612,
                                    "src": "6694:14:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                                      "typeString": "uint256[] memory"
                                    }
                                  },
                                  "id": 11808,
                                  "indexExpression": {
                                    "argumentTypes": null,
                                    "commonType": {
                                      "typeIdentifier": "t_uint256",
                                      "typeString": "uint256"
                                    },
                                    "id": 11807,
                                    "isConstant": false,
                                    "isLValue": false,
                                    "isPure": false,
                                    "lValueRequested": false,
                                    "leftExpression": {
                                      "argumentTypes": null,
                                      "expression": {
                                        "argumentTypes": null,
                                        "id": 11804,
                                        "name": "_marketIdsPath",
                                        "nodeType": "Identifier",
                                        "overloadedDeclarations": [],
                                        "referencedDeclaration": 11612,
                                        "src": "6709:14:52",
                                        "typeDescriptions": {
                                          "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                                          "typeString": "uint256[] memory"
                                        }
                                      },
                                      "id": 11805,
                                      "isConstant": false,
                                      "isLValue": false,
                                      "isPure": false,
                                      "lValueRequested": false,
                                      "memberName": "length",
                                      "nodeType": "MemberAccess",
                                      "referencedDeclaration": null,
                                      "src": "6709:21:52",
                                      "typeDescriptions": {
                                        "typeIdentifier": "t_uint256",
                                        "typeString": "uint256"
                                      }
                                    },
                                    "nodeType": "BinaryOperation",
                                    "operator": "-",
                                    "rightExpression": {
                                      "argumentTypes": null,
                                      "hexValue": "31",
                                      "id": 11806,
                                      "isConstant": false,
                                      "isLValue": false,
                                      "isPure": true,
                                      "kind": "number",
                                      "lValueRequested": false,
                                      "nodeType": "Literal",
                                      "src": "6733:1:52",
                                      "subdenomination": null,
                                      "typeDescriptions": {
                                        "typeIdentifier": "t_rational_1_by_1",
                                        "typeString": "int_const 1"
                                      },
                                      "value": "1"
                                    },
                                    "src": "6709:25:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_uint256",
                                      "typeString": "uint256"
                                    }
                                  },
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "nodeType": "IndexAccess",
                                  "src": "6694:41:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                }
                              ],
                              "expression": {
                                "argumentTypes": [
                                  {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                ],
                                "expression": {
                                  "argumentTypes": null,
                                  "expression": {
                                    "argumentTypes": null,
                                    "id": 11800,
                                    "name": "_cache",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11607,
                                    "src": "6650:6:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                      "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                                    }
                                  },
                                  "id": 11801,
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "memberName": "dolomiteMargin",
                                  "nodeType": "MemberAccess",
                                  "referencedDeclaration": 4590,
                                  "src": "6650:21:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_contract$_IDolomiteMargin_$24693",
                                    "typeString": "contract IDolomiteMargin"
                                  }
                                },
                                "id": 11802,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": false,
                                "lValueRequested": false,
                                "memberName": "getMarketTokenAddress",
                                "nodeType": "MemberAccess",
                                "referencedDeclaration": 24229,
                                "src": "6650:43:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_function_external_view$_t_uint256_$returns$_t_address_$",
                                  "typeString": "function (uint256) view external returns (address)"
                                }
                              },
                              "id": 11809,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "kind": "functionCall",
                              "lValueRequested": false,
                              "names": [],
                              "nodeType": "FunctionCall",
                              "src": "6650:86:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "arguments": [
                                {
                                  "argumentTypes": null,
                                  "expression": {
                                    "argumentTypes": null,
                                    "baseExpression": {
                                      "argumentTypes": null,
                                      "expression": {
                                        "argumentTypes": null,
                                        "id": 11813,
                                        "name": "_param",
                                        "nodeType": "Identifier",
                                        "overloadedDeclarations": [],
                                        "referencedDeclaration": 11614,
                                        "src": "6823:6:52",
                                        "typeDescriptions": {
                                          "typeIdentifier": "t_struct$_TransferCollateralParam_$4640_memory_ptr",
                                          "typeString": "struct IGenericTraderProxyV1.TransferCollateralParam memory"
                                        }
                                      },
                                      "id": 11814,
                                      "isConstant": false,
                                      "isLValue": true,
                                      "isPure": false,
                                      "lValueRequested": false,
                                      "memberName": "transferAmounts",
                                      "nodeType": "MemberAccess",
                                      "referencedDeclaration": 4639,
                                      "src": "6823:22:52",
                                      "typeDescriptions": {
                                        "typeIdentifier": "t_array$_t_struct$_TransferAmount_$4632_memory_$dyn_memory",
                                        "typeString": "struct IGenericTraderProxyV1.TransferAmount memory[] memory"
                                      }
                                    },
                                    "id": 11816,
                                    "indexExpression": {
                                      "argumentTypes": null,
                                      "hexValue": "30",
                                      "id": 11815,
                                      "isConstant": false,
                                      "isLValue": false,
                                      "isPure": true,
                                      "kind": "number",
                                      "lValueRequested": false,
                                      "nodeType": "Literal",
                                      "src": "6846:1:52",
                                      "subdenomination": null,
                                      "typeDescriptions": {
                                        "typeIdentifier": "t_rational_0_by_1",
                                        "typeString": "int_const 0"
                                      },
                                      "value": "0"
                                    },
                                    "isConstant": false,
                                    "isLValue": true,
                                    "isPure": false,
                                    "lValueRequested": false,
                                    "nodeType": "IndexAccess",
                                    "src": "6823:25:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_struct$_TransferAmount_$4632_memory",
                                      "typeString": "struct IGenericTraderProxyV1.TransferAmount memory"
                                    }
                                  },
                                  "id": 11817,
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "memberName": "marketId",
                                  "nodeType": "MemberAccess",
                                  "referencedDeclaration": 4629,
                                  "src": "6823:34:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                }
                              ],
                              "expression": {
                                "argumentTypes": [
                                  {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                ],
                                "expression": {
                                  "argumentTypes": null,
                                  "expression": {
                                    "argumentTypes": null,
                                    "id": 11810,
                                    "name": "_cache",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11607,
                                    "src": "6779:6:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                      "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                                    }
                                  },
                                  "id": 11811,
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "memberName": "dolomiteMargin",
                                  "nodeType": "MemberAccess",
                                  "referencedDeclaration": 4590,
                                  "src": "6779:21:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_contract$_IDolomiteMargin_$24693",
                                    "typeString": "contract IDolomiteMargin"
                                  }
                                },
                                "id": 11812,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": false,
                                "lValueRequested": false,
                                "memberName": "getMarketTokenAddress",
                                "nodeType": "MemberAccess",
                                "referencedDeclaration": 24229,
                                "src": "6779:43:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_function_external_view$_t_uint256_$returns$_t_address_$",
                                  "typeString": "function (uint256) view external returns (address)"
                                }
                              },
                              "id": 11818,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "kind": "functionCall",
                              "lValueRequested": false,
                              "names": [],
                              "nodeType": "FunctionCall",
                              "src": "6779:79:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "id": 11819,
                              "name": "inputBalanceUpdate",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 11620,
                              "src": "6876:18:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                                "typeString": "struct Events.BalanceUpdate memory"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "id": 11820,
                              "name": "outputBalanceUpdate",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 11658,
                              "src": "6912:19:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                                "typeString": "struct Events.BalanceUpdate memory"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "id": 11821,
                              "name": "marginBalanceUpdate",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 11702,
                              "src": "6949:19:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                                "typeString": "struct Events.BalanceUpdate memory"
                              }
                            }
                          ],
                          "expression": {
                            "argumentTypes": [
                              {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              },
                              {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              },
                              {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              },
                              {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              },
                              {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              },
                              {
                                "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                                "typeString": "struct Events.BalanceUpdate memory"
                              },
                              {
                                "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                                "typeString": "struct Events.BalanceUpdate memory"
                              },
                              {
                                "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                                "typeString": "struct Events.BalanceUpdate memory"
                              }
                            ],
                            "expression": {
                              "argumentTypes": null,
                              "expression": {
                                "argumentTypes": null,
                                "id": 11784,
                                "name": "_cache",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 11607,
                                "src": "6385:6:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                  "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                                }
                              },
                              "id": 11787,
                              "isConstant": false,
                              "isLValue": true,
                              "isPure": false,
                              "lValueRequested": false,
                              "memberName": "eventEmitterRegistry",
                              "nodeType": "MemberAccess",
                              "referencedDeclaration": 4592,
                              "src": "6385:27:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_contract$_IEventEmitterRegistry_$4498",
                                "typeString": "contract IEventEmitterRegistry"
                              }
                            },
                            "id": 11788,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": false,
                            "lValueRequested": false,
                            "memberName": "emitMarginPositionClose",
                            "nodeType": "MemberAccess",
                            "referencedDeclaration": 4497,
                            "src": "6385:51:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$_t_address_$_t_address_$_t_address_$_t_struct$_BalanceUpdate_$26624_memory_ptr_$_t_struct$_BalanceUpdate_$26624_memory_ptr_$_t_struct$_BalanceUpdate_$26624_memory_ptr_$returns$__$",
                              "typeString": "function (address,uint256,address,address,address,struct Events.BalanceUpdate memory,struct Events.BalanceUpdate memory,struct Events.BalanceUpdate memory) external"
                            }
                          },
                          "id": 11822,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "kind": "functionCall",
                          "lValueRequested": false,
                          "names": [],
                          "nodeType": "FunctionCall",
                          "src": "6385:597:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_tuple$__$",
                            "typeString": "tuple()"
                          }
                        },
                        "id": 11823,
                        "nodeType": "ExpressionStatement",
                        "src": "6385:597:52"
                      }
                    ]
                  },
                  "id": 11825,
                  "nodeType": "IfStatement",
                  "src": "5719:1274:52",
                  "trueBody": {
                    "id": 11783,
                    "nodeType": "Block",
                    "src": "5747:618:52",
                    "statements": [
                      {
                        "expression": {
                          "argumentTypes": null,
                          "arguments": [
                            {
                              "argumentTypes": null,
                              "expression": {
                                "argumentTypes": null,
                                "id": 11748,
                                "name": "_tradeAccount",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 11609,
                                "src": "5829:13:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                                  "typeString": "struct Account.Info memory"
                                }
                              },
                              "id": 11749,
                              "isConstant": false,
                              "isLValue": true,
                              "isPure": false,
                              "lValueRequested": false,
                              "memberName": "owner",
                              "nodeType": "MemberAccess",
                              "referencedDeclaration": 24848,
                              "src": "5829:19:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "expression": {
                                "argumentTypes": null,
                                "id": 11750,
                                "name": "_tradeAccount",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 11609,
                                "src": "5866:13:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                                  "typeString": "struct Account.Info memory"
                                }
                              },
                              "id": 11751,
                              "isConstant": false,
                              "isLValue": true,
                              "isPure": false,
                              "lValueRequested": false,
                              "memberName": "number",
                              "nodeType": "MemberAccess",
                              "referencedDeclaration": 24850,
                              "src": "5866:20:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "arguments": [
                                {
                                  "argumentTypes": null,
                                  "baseExpression": {
                                    "argumentTypes": null,
                                    "id": 11755,
                                    "name": "_marketIdsPath",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11612,
                                    "src": "5968:14:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                                      "typeString": "uint256[] memory"
                                    }
                                  },
                                  "id": 11757,
                                  "indexExpression": {
                                    "argumentTypes": null,
                                    "hexValue": "30",
                                    "id": 11756,
                                    "isConstant": false,
                                    "isLValue": false,
                                    "isPure": true,
                                    "kind": "number",
                                    "lValueRequested": false,
                                    "nodeType": "Literal",
                                    "src": "5983:1:52",
                                    "subdenomination": null,
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_rational_0_by_1",
                                      "typeString": "int_const 0"
                                    },
                                    "value": "0"
                                  },
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "nodeType": "IndexAccess",
                                  "src": "5968:17:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                }
                              ],
                              "expression": {
                                "argumentTypes": [
                                  {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                ],
                                "expression": {
                                  "argumentTypes": null,
                                  "expression": {
                                    "argumentTypes": null,
                                    "id": 11752,
                                    "name": "_cache",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11607,
                                    "src": "5924:6:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                      "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                                    }
                                  },
                                  "id": 11753,
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "memberName": "dolomiteMargin",
                                  "nodeType": "MemberAccess",
                                  "referencedDeclaration": 4590,
                                  "src": "5924:21:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_contract$_IDolomiteMargin_$24693",
                                    "typeString": "contract IDolomiteMargin"
                                  }
                                },
                                "id": 11754,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": false,
                                "lValueRequested": false,
                                "memberName": "getMarketTokenAddress",
                                "nodeType": "MemberAccess",
                                "referencedDeclaration": 24229,
                                "src": "5924:43:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_function_external_view$_t_uint256_$returns$_t_address_$",
                                  "typeString": "function (uint256) view external returns (address)"
                                }
                              },
                              "id": 11758,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "kind": "functionCall",
                              "lValueRequested": false,
                              "names": [],
                              "nodeType": "FunctionCall",
                              "src": "5924:62:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "arguments": [
                                {
                                  "argumentTypes": null,
                                  "baseExpression": {
                                    "argumentTypes": null,
                                    "id": 11762,
                                    "name": "_marketIdsPath",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11612,
                                    "src": "6069:14:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                                      "typeString": "uint256[] memory"
                                    }
                                  },
                                  "id": 11767,
                                  "indexExpression": {
                                    "argumentTypes": null,
                                    "commonType": {
                                      "typeIdentifier": "t_uint256",
                                      "typeString": "uint256"
                                    },
                                    "id": 11766,
                                    "isConstant": false,
                                    "isLValue": false,
                                    "isPure": false,
                                    "lValueRequested": false,
                                    "leftExpression": {
                                      "argumentTypes": null,
                                      "expression": {
                                        "argumentTypes": null,
                                        "id": 11763,
                                        "name": "_marketIdsPath",
                                        "nodeType": "Identifier",
                                        "overloadedDeclarations": [],
                                        "referencedDeclaration": 11612,
                                        "src": "6084:14:52",
                                        "typeDescriptions": {
                                          "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                                          "typeString": "uint256[] memory"
                                        }
                                      },
                                      "id": 11764,
                                      "isConstant": false,
                                      "isLValue": false,
                                      "isPure": false,
                                      "lValueRequested": false,
                                      "memberName": "length",
                                      "nodeType": "MemberAccess",
                                      "referencedDeclaration": null,
                                      "src": "6084:21:52",
                                      "typeDescriptions": {
                                        "typeIdentifier": "t_uint256",
                                        "typeString": "uint256"
                                      }
                                    },
                                    "nodeType": "BinaryOperation",
                                    "operator": "-",
                                    "rightExpression": {
                                      "argumentTypes": null,
                                      "hexValue": "31",
                                      "id": 11765,
                                      "isConstant": false,
                                      "isLValue": false,
                                      "isPure": true,
                                      "kind": "number",
                                      "lValueRequested": false,
                                      "nodeType": "Literal",
                                      "src": "6108:1:52",
                                      "subdenomination": null,
                                      "typeDescriptions": {
                                        "typeIdentifier": "t_rational_1_by_1",
                                        "typeString": "int_const 1"
                                      },
                                      "value": "1"
                                    },
                                    "src": "6084:25:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_uint256",
                                      "typeString": "uint256"
                                    }
                                  },
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "nodeType": "IndexAccess",
                                  "src": "6069:41:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                }
                              ],
                              "expression": {
                                "argumentTypes": [
                                  {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                ],
                                "expression": {
                                  "argumentTypes": null,
                                  "expression": {
                                    "argumentTypes": null,
                                    "id": 11759,
                                    "name": "_cache",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11607,
                                    "src": "6025:6:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                      "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                                    }
                                  },
                                  "id": 11760,
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "memberName": "dolomiteMargin",
                                  "nodeType": "MemberAccess",
                                  "referencedDeclaration": 4590,
                                  "src": "6025:21:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_contract$_IDolomiteMargin_$24693",
                                    "typeString": "contract IDolomiteMargin"
                                  }
                                },
                                "id": 11761,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": false,
                                "lValueRequested": false,
                                "memberName": "getMarketTokenAddress",
                                "nodeType": "MemberAccess",
                                "referencedDeclaration": 24229,
                                "src": "6025:43:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_function_external_view$_t_uint256_$returns$_t_address_$",
                                  "typeString": "function (uint256) view external returns (address)"
                                }
                              },
                              "id": 11768,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "kind": "functionCall",
                              "lValueRequested": false,
                              "names": [],
                              "nodeType": "FunctionCall",
                              "src": "6025:86:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "arguments": [
                                {
                                  "argumentTypes": null,
                                  "expression": {
                                    "argumentTypes": null,
                                    "baseExpression": {
                                      "argumentTypes": null,
                                      "expression": {
                                        "argumentTypes": null,
                                        "id": 11772,
                                        "name": "_param",
                                        "nodeType": "Identifier",
                                        "overloadedDeclarations": [],
                                        "referencedDeclaration": 11614,
                                        "src": "6195:6:52",
                                        "typeDescriptions": {
                                          "typeIdentifier": "t_struct$_TransferCollateralParam_$4640_memory_ptr",
                                          "typeString": "struct IGenericTraderProxyV1.TransferCollateralParam memory"
                                        }
                                      },
                                      "id": 11773,
                                      "isConstant": false,
                                      "isLValue": true,
                                      "isPure": false,
                                      "lValueRequested": false,
                                      "memberName": "transferAmounts",
                                      "nodeType": "MemberAccess",
                                      "referencedDeclaration": 4639,
                                      "src": "6195:22:52",
                                      "typeDescriptions": {
                                        "typeIdentifier": "t_array$_t_struct$_TransferAmount_$4632_memory_$dyn_memory",
                                        "typeString": "struct IGenericTraderProxyV1.TransferAmount memory[] memory"
                                      }
                                    },
                                    "id": 11775,
                                    "indexExpression": {
                                      "argumentTypes": null,
                                      "hexValue": "30",
                                      "id": 11774,
                                      "isConstant": false,
                                      "isLValue": false,
                                      "isPure": true,
                                      "kind": "number",
                                      "lValueRequested": false,
                                      "nodeType": "Literal",
                                      "src": "6218:1:52",
                                      "subdenomination": null,
                                      "typeDescriptions": {
                                        "typeIdentifier": "t_rational_0_by_1",
                                        "typeString": "int_const 0"
                                      },
                                      "value": "0"
                                    },
                                    "isConstant": false,
                                    "isLValue": true,
                                    "isPure": false,
                                    "lValueRequested": false,
                                    "nodeType": "IndexAccess",
                                    "src": "6195:25:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_struct$_TransferAmount_$4632_memory",
                                      "typeString": "struct IGenericTraderProxyV1.TransferAmount memory"
                                    }
                                  },
                                  "id": 11776,
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "memberName": "marketId",
                                  "nodeType": "MemberAccess",
                                  "referencedDeclaration": 4629,
                                  "src": "6195:34:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                }
                              ],
                              "expression": {
                                "argumentTypes": [
                                  {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                ],
                                "expression": {
                                  "argumentTypes": null,
                                  "expression": {
                                    "argumentTypes": null,
                                    "id": 11769,
                                    "name": "_cache",
                                    "nodeType": "Identifier",
                                    "overloadedDeclarations": [],
                                    "referencedDeclaration": 11607,
                                    "src": "6151:6:52",
                                    "typeDescriptions": {
                                      "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                      "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                                    }
                                  },
                                  "id": 11770,
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "memberName": "dolomiteMargin",
                                  "nodeType": "MemberAccess",
                                  "referencedDeclaration": 4590,
                                  "src": "6151:21:52",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_contract$_IDolomiteMargin_$24693",
                                    "typeString": "contract IDolomiteMargin"
                                  }
                                },
                                "id": 11771,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": false,
                                "lValueRequested": false,
                                "memberName": "getMarketTokenAddress",
                                "nodeType": "MemberAccess",
                                "referencedDeclaration": 24229,
                                "src": "6151:43:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_function_external_view$_t_uint256_$returns$_t_address_$",
                                  "typeString": "function (uint256) view external returns (address)"
                                }
                              },
                              "id": 11777,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "kind": "functionCall",
                              "lValueRequested": false,
                              "names": [],
                              "nodeType": "FunctionCall",
                              "src": "6151:79:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "id": 11778,
                              "name": "inputBalanceUpdate",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 11620,
                              "src": "6248:18:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                                "typeString": "struct Events.BalanceUpdate memory"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "id": 11779,
                              "name": "outputBalanceUpdate",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 11658,
                              "src": "6284:19:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                                "typeString": "struct Events.BalanceUpdate memory"
                              }
                            },
                            {
                              "argumentTypes": null,
                              "id": 11780,
                              "name": "marginBalanceUpdate",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 11702,
                              "src": "6321:19:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                                "typeString": "struct Events.BalanceUpdate memory"
                              }
                            }
                          ],
                          "expression": {
                            "argumentTypes": [
                              {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              },
                              {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              },
                              {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              },
                              {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              },
                              {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              },
                              {
                                "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                                "typeString": "struct Events.BalanceUpdate memory"
                              },
                              {
                                "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                                "typeString": "struct Events.BalanceUpdate memory"
                              },
                              {
                                "typeIdentifier": "t_struct$_BalanceUpdate_$26624_memory_ptr",
                                "typeString": "struct Events.BalanceUpdate memory"
                              }
                            ],
                            "expression": {
                              "argumentTypes": null,
                              "expression": {
                                "argumentTypes": null,
                                "id": 11743,
                                "name": "_cache",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 11607,
                                "src": "5761:6:52",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                                  "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache memory"
                                }
                              },
                              "id": 11746,
                              "isConstant": false,
                              "isLValue": true,
                              "isPure": false,
                              "lValueRequested": false,
                              "memberName": "eventEmitterRegistry",
                              "nodeType": "MemberAccess",
                              "referencedDeclaration": 4592,
                              "src": "5761:27:52",
                              "typeDescriptions": {
                                "typeIdentifier": "t_contract$_IEventEmitterRegistry_$4498",
                                "typeString": "contract IEventEmitterRegistry"
                              }
                            },
                            "id": 11747,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": false,
                            "lValueRequested": false,
                            "memberName": "emitMarginPositionOpen",
                            "nodeType": "MemberAccess",
                            "referencedDeclaration": 4478,
                            "src": "5761:50:52",
                            "typeDescriptions": {
                              "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$_t_address_$_t_address_$_t_address_$_t_struct$_BalanceUpdate_$26624_memory_ptr_$_t_struct$_BalanceUpdate_$26624_memory_ptr_$_t_struct$_BalanceUpdate_$26624_memory_ptr_$returns$__$",
                              "typeString": "function (address,uint256,address,address,address,struct Events.BalanceUpdate memory,struct Events.BalanceUpdate memory,struct Events.BalanceUpdate memory) external"
                            }
                          },
                          "id": 11781,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "kind": "functionCall",
                          "lValueRequested": false,
                          "names": [],
                          "nodeType": "FunctionCall",
                          "src": "5761:593:52",
                          "typeDescriptions": {
                            "typeIdentifier": "t_tuple$__$",
                            "typeString": "tuple()"
                          }
                        },
                        "id": 11782,
                        "nodeType": "ExpressionStatement",
                        "src": "5761:593:52"
                      }
                    ]
                  }
                }
              ]
            },
            "documentation": null,
            "id": 11827,
            "implemented": true,
            "kind": "function",
            "modifiers": [],
            "name": "_logMarginPositionEvent",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 11615,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 11607,
                  "name": "_cache",
                  "nodeType": "VariableDeclaration",
                  "scope": 11827,
                  "src": "3536:61:52",
                  "stateVariable": false,
                  "storageLocation": "memory",
                  "typeDescriptions": {
                    "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_memory_ptr",
                    "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache"
                  },
                  "typeName": {
                    "contractScope": null,
                    "id": 11606,
                    "name": "IGenericTraderProxyBase.GenericTraderProxyCache",
                    "nodeType": "UserDefinedTypeName",
                    "referencedDeclaration": 4607,
                    "src": "3536:47:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_struct$_GenericTraderProxyCache_$4607_storage_ptr",
                      "typeString": "struct IGenericTraderProxyBase.GenericTraderProxyCache"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 11609,
                  "name": "_tradeAccount",
                  "nodeType": "VariableDeclaration",
                  "scope": 11827,
                  "src": "3607:33:52",
                  "stateVariable": false,
                  "storageLocation": "memory",
                  "typeDescriptions": {
                    "typeIdentifier": "t_struct$_Info_$24851_memory_ptr",
                    "typeString": "struct Account.Info"
                  },
                  "typeName": {
                    "contractScope": null,
                    "id": 11608,
                    "name": "Account.Info",
                    "nodeType": "UserDefinedTypeName",
                    "referencedDeclaration": 24851,
                    "src": "3607:12:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_struct$_Info_$24851_storage_ptr",
                      "typeString": "struct Account.Info"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 11612,
                  "name": "_marketIdsPath",
                  "nodeType": "VariableDeclaration",
                  "scope": 11827,
                  "src": "3650:31:52",
                  "stateVariable": false,
                  "storageLocation": "memory",
                  "typeDescriptions": {
                    "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
                    "typeString": "uint256[]"
                  },
                  "typeName": {
                    "baseType": {
                      "id": 11610,
                      "name": "uint256",
                      "nodeType": "ElementaryTypeName",
                      "src": "3650:7:52",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "id": 11611,
                    "length": null,
                    "nodeType": "ArrayTypeName",
                    "src": "3650:9:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_array$_t_uint256_$dyn_storage_ptr",
                      "typeString": "uint256[]"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 11614,
                  "name": "_param",
                  "nodeType": "VariableDeclaration",
                  "scope": 11827,
                  "src": "3691:59:52",
                  "stateVariable": false,
                  "storageLocation": "memory",
                  "typeDescriptions": {
                    "typeIdentifier": "t_struct$_TransferCollateralParam_$4640_memory_ptr",
                    "typeString": "struct IGenericTraderProxyV1.TransferCollateralParam"
                  },
                  "typeName": {
                    "contractScope": null,
                    "id": 11613,
                    "name": "IGenericTraderProxyV1.TransferCollateralParam",
                    "nodeType": "UserDefinedTypeName",
                    "referencedDeclaration": 4640,
                    "src": "3691:45:52",
                    "typeDescriptions": {
                      "typeIdentifier": "t_struct$_TransferCollateralParam_$4640_storage_ptr",
                      "typeString": "struct IGenericTraderProxyV1.TransferCollateralParam"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "3526:230:52"
            },
            "returnParameters": {
              "id": 11616,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "3766:0:52"
            },
            "scope": 11828,
            "src": "3494:3505:52",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "internal"
          }
        ],
        "scope": 11829,
        "src": "2035:4966:52"
      }
    ],
    "src": "595:6407:52"
  },
  "compiler": {
    "name": "solc",
    "version": "0.5.16+commit.9c3226ce.Emscripten.clang"
  },
  "networks": {},
  "schemaVersion": "3.0.23",
  "updatedAt": "2026-03-02T16:38:28.688Z",
  "devdoc": {
    "author": "Dolomite",
    "details": "Library contract for reducing code size of the GenericTraderProxyV1 contract",
    "methods": {},
    "title": "GenericTraderProxyV1Lib"
  },
  "userdoc": {
    "methods": {}
  }
}