@dolomite-exchange/dolomite-margin
Version:
Ethereum Smart Contracts and TypeScript library used for the DolomiteMargin trading protocol
1,094 lines • 62.3 kB
JSON
{
"contractName": "ErroringOmiseToken",
"abi": [
{
"anonymous": false,
"inputs": [
{
"indexed": false,
"internalType": "address",
"name": "token",
"type": "address"
},
{
"indexed": false,
"internalType": "address",
"name": "owner",
"type": "address"
},
{
"indexed": false,
"internalType": "address",
"name": "spender",
"type": "address"
},
{
"indexed": false,
"internalType": "uint256",
"name": "value",
"type": "uint256"
}
],
"name": "Approval",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": false,
"internalType": "address",
"name": "token",
"type": "address"
},
{
"indexed": false,
"internalType": "address",
"name": "owner",
"type": "address"
},
{
"indexed": false,
"internalType": "uint256",
"name": "value",
"type": "uint256"
}
],
"name": "Issue",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": false,
"internalType": "address",
"name": "token",
"type": "address"
},
{
"indexed": false,
"internalType": "address",
"name": "from",
"type": "address"
},
{
"indexed": false,
"internalType": "address",
"name": "to",
"type": "address"
},
{
"indexed": false,
"internalType": "uint256",
"name": "value",
"type": "uint256"
}
],
"name": "Transfer",
"type": "event"
},
{
"constant": true,
"inputs": [
{
"internalType": "address",
"name": "owner",
"type": "address"
},
{
"internalType": "address",
"name": "spender",
"type": "address"
}
],
"name": "allowance",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"payable": false,
"stateMutability": "view",
"type": "function"
},
{
"constant": true,
"inputs": [
{
"internalType": "address",
"name": "who",
"type": "address"
}
],
"name": "balanceOf",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"payable": false,
"stateMutability": "view",
"type": "function"
},
{
"constant": true,
"inputs": [],
"name": "decimals",
"outputs": [
{
"internalType": "uint8",
"name": "",
"type": "uint8"
}
],
"payable": false,
"stateMutability": "pure",
"type": "function"
},
{
"constant": false,
"inputs": [
{
"internalType": "uint256",
"name": "amount",
"type": "uint256"
}
],
"name": "issue",
"outputs": [],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": false,
"inputs": [
{
"internalType": "address",
"name": "who",
"type": "address"
},
{
"internalType": "uint256",
"name": "amount",
"type": "uint256"
}
],
"name": "issueTo",
"outputs": [],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": true,
"inputs": [],
"name": "name",
"outputs": [
{
"internalType": "string",
"name": "",
"type": "string"
}
],
"payable": false,
"stateMutability": "pure",
"type": "function"
},
{
"constant": true,
"inputs": [],
"name": "symbol",
"outputs": [
{
"internalType": "string",
"name": "",
"type": "string"
}
],
"payable": false,
"stateMutability": "pure",
"type": "function"
},
{
"constant": true,
"inputs": [],
"name": "totalSupply",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"payable": false,
"stateMutability": "view",
"type": "function"
},
{
"constant": false,
"inputs": [
{
"internalType": "address",
"name": "",
"type": "address"
},
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"name": "transfer",
"outputs": [],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": false,
"inputs": [
{
"internalType": "address",
"name": "",
"type": "address"
},
{
"internalType": "address",
"name": "",
"type": "address"
},
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"name": "transferFrom",
"outputs": [],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": false,
"inputs": [
{
"internalType": "address",
"name": "",
"type": "address"
},
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"name": "approve",
"outputs": [],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
}
],
"metadata": "{\"compiler\":{\"version\":\"0.5.16+commit.9c3226ce\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"token\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"token\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Issue\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"token\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"constant\":true,\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"internalType\":\"address\",\"name\":\"who\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"decimals\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"payable\":false,\"stateMutability\":\"pure\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"issue\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"internalType\":\"address\",\"name\":\"who\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"issueTo\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"name\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"pure\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"symbol\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"pure\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"}],\"devdoc\":{\"methods\":{}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/home/cdc218/projects/dolomite-protocol-v2/contracts/testing/ErroringOmiseToken.sol\":\"ErroringOmiseToken\"},\"evmVersion\":\"istanbul\",\"libraries\":{},\"optimizer\":{\"enabled\":true,\"runs\":10000},\"remappings\":[]},\"sources\":{\"/home/cdc218/projects/dolomite-protocol-v2/contracts/testing/ErroringOmiseToken.sol\":{\"keccak256\":\"0x45d8fc2dc17a154da9e89dee3fd5a81efa633ac60392229172a7a968f707846e\",\"urls\":[\"bzz-raw://1de6dada9a9ad0cb9089b58958289b44462b8973ff80691d4ae6e0219a4a7928\",\"dweb:/ipfs/Qmay9iX4oSwjfuxgZiSHqdvtwsLkePGyyQwxAXDZvuH6pW\"]},\"/home/cdc218/projects/dolomite-protocol-v2/contracts/testing/OmiseToken.sol\":{\"keccak256\":\"0xa75033c87297b84a758be97971af549a800fa95c2e3712141322792ab0359318\",\"urls\":[\"bzz-raw://0fa71edd30b29032e08db8c44fef82c8a384d2aa5cfd541e776af84ac4b72b63\",\"dweb:/ipfs/QmSX22SfTtzB9nsxQteyWwU3An7qEr4f6pTmvMNHTrinbH\"]},\"@openzeppelin/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzz-raw://31113152e1ddb78fe7a4197f247591ca894e93f916867beb708d8e747b6cc74f\",\"dweb:/ipfs/QmbZaJyXdpsYGykVhHH9qpVGQg9DGCxE2QufbCUy3daTgq\"]}},\"version\":1}",
"bytecode": "0x608060405234801561001057600080fd5b5061066c806100206000396000f3fe608060405234801561001057600080fd5b50600436106100c95760003560e01c8063313ce56711610081578063a9059cbb1161005b578063a9059cbb146100ec578063cc872b6614610167578063dd62ed3e1461017a576100c9565b8063313ce5671461013757806370a082311461014c57806395d89b411461015f576100c9565b80631207f0c1116100b25780631207f0c11461010157806318160ddd1461011457806323b872dd14610129576100c9565b806306fdde03146100ce578063095ea7b3146100ec575b600080fd5b6100d661018d565b6040516100e39190610543565b60405180910390f35b6100ff6100fa36600461043b565b6100c9565b005b6100ff61010f36600461043b565b6101c4565b61011c610278565b6040516100e39190610564565b6100ff6100fa3660046103ee565b61013f61027e565b6040516100e39190610572565b61011c61015a36600461038e565b610283565b6100d66102ab565b6100ff61017536600461046b565b6102e2565b61011c6101883660046103b4565b6102ef565b60408051808201909152600a81527f54657374204f6d69736500000000000000000000000000000000000000000000602082015290565b6000546101d7908263ffffffff61032916565b600090815573ffffffffffffffffffffffffffffffffffffffff831681526001602052604090205461020f908263ffffffff61032916565b73ffffffffffffffffffffffffffffffffffffffff83166000908152600160205260409081902091909155517f4b2682685b046a3dae8e75ff49b82fa703e366056a43c6a791411011134f4f5d9061026c9030908590859061051b565b60405180910390a15050565b60005490565b601290565b73ffffffffffffffffffffffffffffffffffffffff1660009081526001602052604090205490565b60408051808201909152600481527f544f4d4700000000000000000000000000000000000000000000000000000000602082015290565b6102ec33826101c4565b50565b73ffffffffffffffffffffffffffffffffffffffff8083166000908152600260209081526040808320938516835292905220545b92915050565b600082820183811015610371576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161036890610554565b60405180910390fd5b9392505050565b80356103238161060c565b803561032381610620565b6000602082840312156103a057600080fd5b60006103ac8484610378565b949350505050565b600080604083850312156103c757600080fd5b60006103d38585610378565b92505060206103e485828601610378565b9150509250929050565b60008060006060848603121561040357600080fd5b600061040f8686610378565b935050602061042086828701610378565b925050604061043186828701610383565b9150509250925092565b6000806040838503121561044e57600080fd5b600061045a8585610378565b92505060206103e485828601610383565b60006020828403121561047d57600080fd5b60006103ac8484610383565b6104928161058d565b82525050565b60006104a382610580565b6104ad8185610584565b93506104bd8185602086016105b4565b6104c6816105e4565b9093019392505050565b60006104dd601b83610584565b7f536166654d6174683a206164646974696f6e206f766572666c6f770000000000815260200192915050565b610492816105ab565b610492816105ae565b606081016105298286610489565b6105366020830185610489565b6103ac6040830184610509565b602080825281016103718184610498565b60208082528101610323816104d0565b602081016103238284610509565b602081016103238284610512565b5190565b90815260200190565b600073ffffffffffffffffffffffffffffffffffffffff8216610323565b90565b60ff1690565b60005b838110156105cf5781810151838201526020016105b7565b838111156105de576000848401525b50505050565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01690565b6106158161058d565b81146102ec57600080fd5b610615816105ab56fea365627a7a72315820f64b813fb7cf8080b32b7894e1fd595ab3d153eddddf71a595fe6a123c063a3a6c6578706572696d656e74616cf564736f6c63430005100040",
"deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100c95760003560e01c8063313ce56711610081578063a9059cbb1161005b578063a9059cbb146100ec578063cc872b6614610167578063dd62ed3e1461017a576100c9565b8063313ce5671461013757806370a082311461014c57806395d89b411461015f576100c9565b80631207f0c1116100b25780631207f0c11461010157806318160ddd1461011457806323b872dd14610129576100c9565b806306fdde03146100ce578063095ea7b3146100ec575b600080fd5b6100d661018d565b6040516100e39190610543565b60405180910390f35b6100ff6100fa36600461043b565b6100c9565b005b6100ff61010f36600461043b565b6101c4565b61011c610278565b6040516100e39190610564565b6100ff6100fa3660046103ee565b61013f61027e565b6040516100e39190610572565b61011c61015a36600461038e565b610283565b6100d66102ab565b6100ff61017536600461046b565b6102e2565b61011c6101883660046103b4565b6102ef565b60408051808201909152600a81527f54657374204f6d69736500000000000000000000000000000000000000000000602082015290565b6000546101d7908263ffffffff61032916565b600090815573ffffffffffffffffffffffffffffffffffffffff831681526001602052604090205461020f908263ffffffff61032916565b73ffffffffffffffffffffffffffffffffffffffff83166000908152600160205260409081902091909155517f4b2682685b046a3dae8e75ff49b82fa703e366056a43c6a791411011134f4f5d9061026c9030908590859061051b565b60405180910390a15050565b60005490565b601290565b73ffffffffffffffffffffffffffffffffffffffff1660009081526001602052604090205490565b60408051808201909152600481527f544f4d4700000000000000000000000000000000000000000000000000000000602082015290565b6102ec33826101c4565b50565b73ffffffffffffffffffffffffffffffffffffffff8083166000908152600260209081526040808320938516835292905220545b92915050565b600082820183811015610371576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161036890610554565b60405180910390fd5b9392505050565b80356103238161060c565b803561032381610620565b6000602082840312156103a057600080fd5b60006103ac8484610378565b949350505050565b600080604083850312156103c757600080fd5b60006103d38585610378565b92505060206103e485828601610378565b9150509250929050565b60008060006060848603121561040357600080fd5b600061040f8686610378565b935050602061042086828701610378565b925050604061043186828701610383565b9150509250925092565b6000806040838503121561044e57600080fd5b600061045a8585610378565b92505060206103e485828601610383565b60006020828403121561047d57600080fd5b60006103ac8484610383565b6104928161058d565b82525050565b60006104a382610580565b6104ad8185610584565b93506104bd8185602086016105b4565b6104c6816105e4565b9093019392505050565b60006104dd601b83610584565b7f536166654d6174683a206164646974696f6e206f766572666c6f770000000000815260200192915050565b610492816105ab565b610492816105ae565b606081016105298286610489565b6105366020830185610489565b6103ac6040830184610509565b602080825281016103718184610498565b60208082528101610323816104d0565b602081016103238284610509565b602081016103238284610512565b5190565b90815260200190565b600073ffffffffffffffffffffffffffffffffffffffff8216610323565b90565b60ff1690565b60005b838110156105cf5781810151838201526020016105b7565b838111156105de576000848401525b50505050565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01690565b6106158161058d565b81146102ec57600080fd5b610615816105ab56fea365627a7a72315820f64b813fb7cf8080b32b7894e1fd595ab3d153eddddf71a595fe6a123c063a3a6c6578706572696d656e74616cf564736f6c63430005100040",
"sourceMap": "711:297:106:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;711:297:106;;;;;;;",
"deployedSourceMap": "711:297:106:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;711:297:106;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1886:88:109;;;:::i;:::-;;;;;;;;;;;;;;;;933:73:106;;;;;;;;;:::i;:::-;;1266:196:109;;;;;;;;;:::i;1468:83::-;;;:::i;:::-;;;;;;;;840:87:106;;;;;;;1980:74:109;;;:::i;:::-;;;;;;;;1557:99;;;;;;;;;:::i;1796:84::-;;;:::i;1178:82::-;;;;;;;;;:::i;1662:128::-;;;;;;;;;:::i;1886:88::-;1948:19;;;;;;;;;;;;;;;;;1886:88;:::o;1266:196::-;1338:6;;:18;;1349:6;1338:18;:10;:18;:::i;:::-;1329:6;:27;;;1382:13;;;;;:8;:13;;;;;;:25;;1400:6;1382:25;:17;:25;:::i;:::-;1366:13;;;;;;;:8;:13;;;;;;;:41;;;;1422:33;;;;;1436:4;;1375:3;;1448:6;;1422:33;;;;;;;;;;1266:196;;:::o;1468:83::-;1512:7;1538:6;1468:83;:::o;1980:74::-;2045:2;1980:74;:::o;1557:99::-;1636:13;;1610:7;1636:13;;;:8;:13;;;;;;;1557:99::o;1796:84::-;1860:13;;;;;;;;;;;;;;;;;1796:84;:::o;1178:82::-;1226:27;1234:10;1246:6;1226:7;:27::i;:::-;1178:82;:::o;1662:128::-;1760:14;;;;1734:7;1760:14;;;:7;:14;;;;;;;;:23;;;;;;;;;;1662:128;;;;;:::o;834:176:150:-;892:7;923:5;;;946:6;;;;938:46;;;;;;;;;;;;;;;;;;;;;;1002:1;834:176;-1:-1:-1;;;834:176:150:o;5:130:-1:-;72:20;;97:33;72:20;97:33;;142:130;209:20;;234:33;209:20;234:33;;279:241;;383:2;371:9;362:7;358:23;354:32;351:2;;;399:1;396;389:12;351:2;434:1;451:53;496:7;476:9;451:53;;;441:63;345:175;-1:-1;;;;345:175;527:366;;;648:2;636:9;627:7;623:23;619:32;616:2;;;664:1;661;654:12;616:2;699:1;716:53;761:7;741:9;716:53;;;706:63;;678:97;806:2;824:53;869:7;860:6;849:9;845:22;824:53;;;814:63;;785:98;610:283;;;;;;900:491;;;;1038:2;1026:9;1017:7;1013:23;1009:32;1006:2;;;1054:1;1051;1044:12;1006:2;1089:1;1106:53;1151:7;1131:9;1106:53;;;1096:63;;1068:97;1196:2;1214:53;1259:7;1250:6;1239:9;1235:22;1214:53;;;1204:63;;1175:98;1304:2;1322:53;1367:7;1358:6;1347:9;1343:22;1322:53;;;1312:63;;1283:98;1000:391;;;;;;1398:366;;;1519:2;1507:9;1498:7;1494:23;1490:32;1487:2;;;1535:1;1532;1525:12;1487:2;1570:1;1587:53;1632:7;1612:9;1587:53;;;1577:63;;1549:97;1677:2;1695:53;1740:7;1731:6;1720:9;1716:22;1695:53;;1771:241;;1875:2;1863:9;1854:7;1850:23;1846:32;1843:2;;;1891:1;1888;1881:12;1843:2;1926:1;1943:53;1988:7;1968:9;1943:53;;2019:113;2102:24;2120:5;2102:24;;;2097:3;2090:37;2084:48;;;2139:347;;2251:39;2284:5;2251:39;;;2302:71;2366:6;2361:3;2302:71;;;2295:78;;2378:52;2423:6;2418:3;2411:4;2404:5;2400:16;2378:52;;;2451:29;2473:6;2451:29;;;2442:39;;;;2231:255;-1:-1;;;2231:255;2494:327;;2654:67;2718:2;2713:3;2654:67;;;2754:29;2734:50;;2812:2;2803:12;;2640:181;-1:-1;;2640:181;2829:113;2912:24;2930:5;2912:24;;2949:107;3028:22;3044:5;3028:22;;3063:435;3237:2;3222:18;;3251:71;3226:9;3295:6;3251:71;;;3333:72;3401:2;3390:9;3386:18;3377:6;3333:72;;;3416;3484:2;3473:9;3469:18;3460:6;3416:72;;3505:301;3643:2;3657:47;;;3628:18;;3718:78;3628:18;3782:6;3718:78;;3813:407;4004:2;4018:47;;;3989:18;;4079:131;3989:18;4079:131;;4227:213;4345:2;4330:18;;4359:71;4334:9;4403:6;4359:71;;4447:205;4561:2;4546:18;;4575:67;4550:9;4615:6;4575:67;;4659:122;4747:12;;4718:63;4789:163;4892:19;;;4941:4;4932:14;;4885:67;4960:91;;5131:42;5120:54;;5022:24;5103:76;5186:72;5248:5;5231:27;5265:81;5336:4;5325:16;;5308:38;5354:268;5419:1;5426:101;5440:6;5437:1;5434:13;5426:101;;;5507:11;;;5501:18;5488:11;;;5481:39;5462:2;5455:10;5426:101;;;5542:6;5539:1;5536:13;5533:2;;;5607:1;5598:6;5593:3;5589:16;5582:27;5533:2;5403:219;;;;;5630:97;5718:2;5698:14;5714:7;5694:28;;5678:49;5735:117;5804:24;5822:5;5804:24;;;5797:5;5794:35;5784:2;;5843:1;5840;5833:12;5859:117;5928:24;5946:5;5928:24;",
"source": "/*\n\n Copyright 2019 dYdX Trading Inc.\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 { OmiseToken } from \"./OmiseToken.sol\";\n\n\ncontract ErroringOmiseToken is OmiseToken {\n\n function transfer(address, uint256) public {\n require(false);\n }\n\n function transferFrom(address, address, uint256) public {\n require(false);\n }\n\n function approve(address, uint256) public {\n require(false);\n }\n}\n",
"sourcePath": "/home/cdc218/projects/dolomite-protocol-v2/contracts/testing/ErroringOmiseToken.sol",
"ast": {
"absolutePath": "/home/cdc218/projects/dolomite-protocol-v2/contracts/testing/ErroringOmiseToken.sol",
"exportedSymbols": {
"ErroringOmiseToken": [
31474
]
},
"id": 31475,
"nodeType": "SourceUnit",
"nodes": [
{
"id": 31430,
"literals": [
"solidity",
"^",
"0.5",
".7"
],
"nodeType": "PragmaDirective",
"src": "603:23:106"
},
{
"id": 31431,
"literals": [
"experimental",
"ABIEncoderV2"
],
"nodeType": "PragmaDirective",
"src": "627:33:106"
},
{
"absolutePath": "/home/cdc218/projects/dolomite-protocol-v2/contracts/testing/OmiseToken.sol",
"file": "./OmiseToken.sol",
"id": 31433,
"nodeType": "ImportDirective",
"scope": 31475,
"sourceUnit": 32215,
"src": "662:46:106",
"symbolAliases": [
{
"foreign": 31432,
"local": null
}
],
"unitAlias": ""
},
{
"baseContracts": [
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 31434,
"name": "OmiseToken",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 32214,
"src": "742:10:106",
"typeDescriptions": {
"typeIdentifier": "t_contract$_OmiseToken_$32214",
"typeString": "contract OmiseToken"
}
},
"id": 31435,
"nodeType": "InheritanceSpecifier",
"src": "742:10:106"
}
],
"contractDependencies": [
32214
],
"contractKind": "contract",
"documentation": null,
"fullyImplemented": true,
"id": 31474,
"linearizedBaseContracts": [
31474,
32214
],
"name": "ErroringOmiseToken",
"nodeType": "ContractDefinition",
"nodes": [
{
"body": {
"id": 31446,
"nodeType": "Block",
"src": "803:31:106",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "66616c7365",
"id": 31443,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "bool",
"lValueRequested": false,
"nodeType": "Literal",
"src": "821:5:106",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"value": "false"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 31442,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
38110,
38111
],
"referencedDeclaration": 38110,
"src": "813:7:106",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 31444,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "813:14:106",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 31445,
"nodeType": "ExpressionStatement",
"src": "813:14:106"
}
]
},
"documentation": null,
"id": 31447,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "transfer",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 31440,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 31437,
"name": "",
"nodeType": "VariableDeclaration",
"scope": 31447,
"src": "778:7:106",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 31436,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "778:7:106",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 31439,
"name": "",
"nodeType": "VariableDeclaration",
"scope": 31447,
"src": "787:7:106",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 31438,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "787:7:106",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "777:18:106"
},
"returnParameters": {
"id": 31441,
"nodeType": "ParameterList",
"parameters": [],
"src": "803:0:106"
},
"scope": 31474,
"src": "760:74:106",
"stateMutability": "nonpayable",
"superFunction": 32111,
"visibility": "public"
},
{
"body": {
"id": 31460,
"nodeType": "Block",
"src": "896:31:106",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "66616c7365",
"id": 31457,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "bool",
"lValueRequested": false,
"nodeType": "Literal",
"src": "914:5:106",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"value": "false"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 31456,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
38110,
38111
],
"referencedDeclaration": 38110,
"src": "906:7:106",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 31458,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "906:14:106",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 31459,
"nodeType": "ExpressionStatement",
"src": "906:14:106"
}
]
},
"documentation": null,
"id": 31461,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "transferFrom",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 31454,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 31449,
"name": "",
"nodeType": "VariableDeclaration",
"scope": 31461,
"src": "862:7:106",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 31448,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "862:7:106",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 31451,
"name": "",
"nodeType": "VariableDeclaration",
"scope": 31461,
"src": "871:7:106",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 31450,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "871:7:106",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 31453,
"name": "",
"nodeType": "VariableDeclaration",
"scope": 31461,
"src": "880:7:106",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 31452,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "880:7:106",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "861:27:106"
},
"returnParameters": {
"id": 31455,
"nodeType": "ParameterList",
"parameters": [],
"src": "896:0:106"
},
"scope": 31474,
"src": "840:87:106",
"stateMutability": "nonpayable",
"superFunction": 32186,
"visibility": "public"
},
{
"body": {
"id": 31472,
"nodeType": "Block",
"src": "975:31:106",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "66616c7365",
"id": 31469,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "bool",
"lValueRequested": false,
"nodeType": "Literal",
"src": "993:5:106",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"value": "false"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 31468,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
38110,
38111
],
"referencedDeclaration": 38110,
"src": "985:7:106",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 31470,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "985:14:106",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 31471,
"nodeType": "ExpressionStatement",
"src": "985:14:106"
}
]
},
"documentation": null,
"id": 31473,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "approve",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 31466,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 31463,
"name": "",
"nodeType": "VariableDeclaration",
"scope": 31473,
"src": "950:7:106",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 31462,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "950:7:106",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 31465,
"name": "",
"nodeType": "VariableDeclaration",
"scope": 31473,
"src": "959:7:106",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 31464,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "959:7:106",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "949:18:106"
},
"returnParameters": {
"id": 31467,
"nodeType": "ParameterList",
"parameters": [],
"src": "975:0:106"
},
"scope": 31474,
"src": "933:73:106",
"stateMutability": "nonpayable",
"superFunction": 32213,
"visibility": "public"
}
],
"scope": 31475,
"src": "711:297:106"
}
],
"src": "603:406:106"
},
"legacyAST": {
"absolutePath": "/home/cdc218/projects/dolomite-protocol-v2/contracts/testing/ErroringOmiseToken.sol",
"exportedSymbols": {
"ErroringOmiseToken": [
31474
]
},
"id": 31475,
"nodeType": "SourceUnit",
"nodes": [
{
"id": 31430,
"literals": [
"solidity",
"^",
"0.5",
".7"
],
"nodeType": "PragmaDirective",
"src": "603:23:106"
},
{
"id": 31431,
"literals": [
"experimental",
"ABIEncoderV2"
],
"nodeType": "PragmaDirective",
"src": "627:33:106"
},
{
"absolutePath": "/home/cdc218/projects/dolomite-protocol-v2/contracts/testing/OmiseToken.sol",
"file": "./OmiseToken.sol",
"id": 31433,
"nodeType": "ImportDirective",
"scope": 31475,
"sourceUnit": 32215,
"src": "662:46:106",
"symbolAliases": [
{
"foreign": 31432,
"local": null
}
],
"unitAlias": ""
},
{
"baseContracts": [
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 31434,
"name": "OmiseToken",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 32214,
"src": "742:10:106",
"typeDescriptions": {
"typeIdentifier": "t_contract$_OmiseToken_$32214",
"typeString": "contract OmiseToken"
}
},
"id": 31435,
"nodeType": "InheritanceSpecifier",
"src": "742:10:106"
}
],
"contractDependencies": [
32214
],
"contractKind": "contract",
"documentation": null,
"fullyImplemented": true,
"id": 31474,
"linearizedBaseContracts": [
31474,
32214
],
"name": "ErroringOmiseToken",
"nodeType": "ContractDefinition",
"nodes": [
{
"body": {
"id": 31446,
"nodeType": "Block",
"src": "803:31:106",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "66616c7365",
"id": 31443,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "bool",
"lValueRequested": false,
"nodeType": "Literal",
"src": "821:5:106",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"value": "false"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 31442,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
38110,
38111
],
"referencedDeclaration": 38110,
"src": "813:7:106",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 31444,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "813:14:106",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 31445,
"nodeType": "ExpressionStatement",
"src": "813:14:106"
}
]
},
"documentation": null,
"id": 31447,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "transfer",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 31440,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 31437,
"name": "",
"nodeType": "VariableDeclaration",
"scope": 31447,
"src": "778:7:106",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 31436,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "778:7:106",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 31439,
"name": "",
"nodeType": "VariableDeclaration",
"scope": 31447,
"src": "787:7:106",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 31438,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "787:7:106",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "777:18:106"
},
"returnParameters": {
"id": 31441,
"nodeType": "ParameterList",
"parameters": [],
"src": "803:0:106"
},
"scope": 31474,
"src": "760:74:106",
"stateMuta