kleros-interaction-2
Version:
Smart contracts interacting with Kleros.
7,242 lines • 331 kB
JSON
{
"contractName": "LockedToken",
"abi": [
{
"constant": true,
"inputs": [],
"name": "mintingFinished",
"outputs": [
{
"name": "",
"type": "bool"
}
],
"payable": false,
"stateMutability": "view",
"type": "function"
},
{
"constant": false,
"inputs": [
{
"name": "_spender",
"type": "address"
},
{
"name": "_value",
"type": "uint256"
}
],
"name": "approve",
"outputs": [
{
"name": "",
"type": "bool"
}
],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": true,
"inputs": [],
"name": "lockMultiplierPerMillionPerMonth",
"outputs": [
{
"name": "",
"type": "uint256"
}
],
"payable": false,
"stateMutability": "view",
"type": "function"
},
{
"constant": true,
"inputs": [],
"name": "totalSupply",
"outputs": [
{
"name": "",
"type": "uint256"
}
],
"payable": false,
"stateMutability": "view",
"type": "function"
},
{
"constant": false,
"inputs": [
{
"name": "_spender",
"type": "address"
},
{
"name": "_subtractedValue",
"type": "uint256"
}
],
"name": "decreaseApproval",
"outputs": [
{
"name": "",
"type": "bool"
}
],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": true,
"inputs": [
{
"name": "_owner",
"type": "address"
}
],
"name": "balanceOf",
"outputs": [
{
"name": "",
"type": "uint256"
}
],
"payable": false,
"stateMutability": "view",
"type": "function"
},
{
"constant": false,
"inputs": [],
"name": "renounceOwnership",
"outputs": [],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": false,
"inputs": [],
"name": "finishMinting",
"outputs": [
{
"name": "",
"type": "bool"
}
],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": true,
"inputs": [],
"name": "owner",
"outputs": [
{
"name": "",
"type": "address"
}
],
"payable": false,
"stateMutability": "view",
"type": "function"
},
{
"constant": true,
"inputs": [
{
"name": "",
"type": "address"
}
],
"name": "lastUnlock",
"outputs": [
{
"name": "",
"type": "uint256"
}
],
"payable": false,
"stateMutability": "view",
"type": "function"
},
{
"constant": false,
"inputs": [
{
"name": "_spender",
"type": "address"
},
{
"name": "_addedValue",
"type": "uint256"
}
],
"name": "increaseApproval",
"outputs": [
{
"name": "",
"type": "bool"
}
],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": true,
"inputs": [
{
"name": "_owner",
"type": "address"
},
{
"name": "_spender",
"type": "address"
}
],
"name": "allowance",
"outputs": [
{
"name": "",
"type": "uint256"
}
],
"payable": false,
"stateMutability": "view",
"type": "function"
},
{
"constant": false,
"inputs": [
{
"name": "_newOwner",
"type": "address"
}
],
"name": "transferOwnership",
"outputs": [],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": true,
"inputs": [
{
"name": "",
"type": "address"
}
],
"name": "amountLocked",
"outputs": [
{
"name": "",
"type": "uint256"
}
],
"payable": false,
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"name": "_lockMultiplierPerMillionPerMonth",
"type": "uint256"
}
],
"payable": false,
"stateMutability": "nonpayable",
"type": "constructor"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"name": "to",
"type": "address"
},
{
"indexed": false,
"name": "amount",
"type": "uint256"
}
],
"name": "Mint",
"type": "event"
},
{
"anonymous": false,
"inputs": [],
"name": "MintFinished",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"name": "previousOwner",
"type": "address"
}
],
"name": "OwnershipRenounced",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"name": "previousOwner",
"type": "address"
},
{
"indexed": true,
"name": "newOwner",
"type": "address"
}
],
"name": "OwnershipTransferred",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"name": "owner",
"type": "address"
},
{
"indexed": true,
"name": "spender",
"type": "address"
},
{
"indexed": false,
"name": "value",
"type": "uint256"
}
],
"name": "Approval",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"name": "from",
"type": "address"
},
{
"indexed": true,
"name": "to",
"type": "address"
},
{
"indexed": false,
"name": "value",
"type": "uint256"
}
],
"name": "Transfer",
"type": "event"
},
{
"constant": false,
"inputs": [
{
"name": "_to",
"type": "address"
},
{
"name": "_amount",
"type": "uint256"
}
],
"name": "mint",
"outputs": [
{
"name": "",
"type": "bool"
}
],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": false,
"inputs": [
{
"name": "_to",
"type": "address"
}
],
"name": "unlock",
"outputs": [],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": false,
"inputs": [
{
"name": "_to",
"type": "address"
},
{
"name": "_maxUnlock",
"type": "uint256"
}
],
"name": "partialUnlock",
"outputs": [],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": false,
"inputs": [
{
"name": "_to",
"type": "address"
},
{
"name": "_value",
"type": "uint256"
}
],
"name": "transfer",
"outputs": [
{
"name": "",
"type": "bool"
}
],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": false,
"inputs": [
{
"name": "_from",
"type": "address"
},
{
"name": "_to",
"type": "address"
},
{
"name": "_value",
"type": "uint256"
}
],
"name": "transferFrom",
"outputs": [
{
"name": "",
"type": "bool"
}
],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
}
],
"bytecode": "0x60806040526003805460a060020a60ff021916905534801561002057600080fd5b50604051602080610f7c833981016040525160038054600160a060020a03191633179055600455610f26806100566000396000f3006080604052600436106101065763ffffffff7c010000000000000000000000000000000000000000000000000000000060003504166305d2035b811461010b578063095ea7b3146101345780630c96d9e71461015857806318160ddd1461017f57806323b872dd146101945780632f6c493c146101be57806340c10f19146101e157806358fa9fe314610205578063661884631461022957806370a082311461024d578063715018a61461026e5780637d64bcb4146102835780638da5cb5b14610298578063a9059cbb146102c9578063cd5d1084146102ed578063d73dd6231461030e578063dd62ed3e14610332578063f2fde38b14610359578063f6c788b21461037a575b600080fd5b34801561011757600080fd5b5061012061039b565b604080519115158252519081900360200190f35b34801561014057600080fd5b50610120600160a060020a03600435166024356103bc565b34801561016457600080fd5b5061016d610423565b60408051918252519081900360200190f35b34801561018b57600080fd5b5061016d610429565b3480156101a057600080fd5b50610120600160a060020a036004358116906024351660443561042f565b3480156101ca57600080fd5b506101df600160a060020a03600435166104fa565b005b3480156101ed57600080fd5b50610120600160a060020a0360043516602435610509565b34801561021157600080fd5b506101df600160a060020a036004351660243561054f565b34801561023557600080fd5b50610120600160a060020a03600435166024356106bb565b34801561025957600080fd5b5061016d600160a060020a03600435166107aa565b34801561027a57600080fd5b506101df6107c5565b34801561028f57600080fd5b50610120610833565b3480156102a457600080fd5b506102ad6108d9565b60408051600160a060020a039092168252519081900360200190f35b3480156102d557600080fd5b50610120600160a060020a03600435166024356108e8565b3480156102f957600080fd5b5061016d600160a060020a03600435166109a8565b34801561031a57600080fd5b50610120600160a060020a03600435166024356109ba565b34801561033e57600080fd5b5061016d600160a060020a0360043581169060243516610a53565b34801561036557600080fd5b506101df600160a060020a0360043516610a7e565b34801561038657600080fd5b5061016d600160a060020a0360043516610a9e565b60035474010000000000000000000000000000000000000000900460ff1681565b336000818152600260209081526040808320600160a060020a038716808552908352818420869055815186815291519394909390927f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925928290030190a35060015b92915050565b60045481565b60015490565b600061043a846104fa565b600160a060020a03841660009081526006602090815260408083205491839052909120548391610470919063ffffffff610ab016565b10156104dd57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f4e6f7420656e6f7567682062616c616e63652e00000000000000000000000000604482015290519081900360640190fd5b6104e8848484610ac2565b15156104f057fe5b5060019392505050565b6105068160001961054f565b50565b6000610514836104fa565b61051e8383610c37565b151561052657fe5b600160a060020a0383166000908152600660205260409020546104f0908363ffffffff610d5216565b600160a060020a038216600090815260056020526040812054819081904290610581906224ea0063ffffffff610d5216565b111580156105a65750600160a060020a03851660009081526006602052604090205415155b156106b457600160a060020a0385166000908152600560205260409020546224ea00906105da90429063ffffffff610ab016565b8115156105e357fe5b0492508383106105f357836105f5565b825b925061063261060d846224ea0063ffffffff610d5f16565b600160a060020a0387166000908152600560205260409020549063ffffffff610d5216565b600160a060020a0386166000908152600560209081526040808320939093556006905290812054925090505b828110156106985761068e620f424061068260045485610d5f90919063ffffffff16565b9063ffffffff610d8816565b915060010161065e565b600160a060020a03851660009081526006602052604090208290555b5050505050565b336000908152600260209081526040808320600160a060020a038616845290915281205480831061070f57336000908152600260209081526040808320600160a060020a0388168452909152812055610744565b61071f818463ffffffff610ab016565b336000908152600260209081526040808320600160a060020a03891684529091529020555b336000818152600260209081526040808320600160a060020a0389168085529083529281902054815190815290519293927f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925929181900390910190a35060019392505050565b600160a060020a031660009081526020819052604090205490565b600354600160a060020a031633146107dc57600080fd5b600354604051600160a060020a03909116907ff8df31144d9c2f0f6b59d69b8b98abd5459d07f2742c4df920b25aae33c6482090600090a26003805473ffffffffffffffffffffffffffffffffffffffff19169055565b600354600090600160a060020a0316331461084d57600080fd5b60035474010000000000000000000000000000000000000000900460ff161561087557600080fd5b6003805474ff00000000000000000000000000000000000000001916740100000000000000000000000000000000000000001790556040517fae5184fba832cb2b1f702aca6117b8d265eaf03ad33eb133f19dde0f5920fa0890600090a150600190565b600354600160a060020a031681565b60006108f3336104fa565b3360009081526006602090815260408083205491839052909120548391610920919063ffffffff610ab016565b101561098d57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f4e6f7420656e6f7567682062616c616e63652e00000000000000000000000000604482015290519081900360640190fd5b6109978383610d9d565b151561099f57fe5b50600192915050565b60056020526000908152604090205481565b336000908152600260209081526040808320600160a060020a03861684529091528120546109ee908363ffffffff610d5216565b336000818152600260209081526040808320600160a060020a0389168085529083529281902085905580519485525191937f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925929081900390910190a350600192915050565b600160a060020a03918216600090815260026020908152604080832093909416825291909152205490565b600354600160a060020a03163314610a9557600080fd5b61050681610e7c565b60066020526000908152604090205481565b600082821115610abc57fe5b50900390565b600160a060020a038316600090815260208190526040812054821115610ae757600080fd5b600160a060020a0384166000908152600260209081526040808320338452909152902054821115610b1757600080fd5b600160a060020a0383161515610b2c57600080fd5b600160a060020a038416600090815260208190526040902054610b55908363ffffffff610ab016565b600160a060020a038086166000908152602081905260408082209390935590851681522054610b8a908363ffffffff610d5216565b600160a060020a03808516600090815260208181526040808320949094559187168152600282528281203382529091522054610bcc908363ffffffff610ab016565b600160a060020a03808616600081815260026020908152604080832033845282529182902094909455805186815290519287169391927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef929181900390910190a35060019392505050565b600354600090600160a060020a03163314610c5157600080fd5b60035474010000000000000000000000000000000000000000900460ff1615610c7957600080fd5b600154610c8c908363ffffffff610d5216565b600155600160a060020a038316600090815260208190526040902054610cb8908363ffffffff610d5216565b600160a060020a03841660008181526020818152604091829020939093558051858152905191927f0f6798a560793a54c3bcfe86a93cde1e73087d944c0ea20544137d412139688592918290030190a2604080518381529051600160a060020a038516916000917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9181900360200190a350600192915050565b8181018281101561041d57fe5b6000821515610d705750600061041d565b50818102818382811515610d8057fe5b041461041d57fe5b60008183811515610d9557fe5b049392505050565b33600090815260208190526040812054821115610db957600080fd5b600160a060020a0383161515610dce57600080fd5b33600090815260208190526040902054610dee908363ffffffff610ab016565b3360009081526020819052604080822092909255600160a060020a03851681522054610e20908363ffffffff610d5216565b600160a060020a038416600081815260208181526040918290209390935580518581529051919233927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9281900390910190a350600192915050565b600160a060020a0381161515610e9157600080fd5b600354604051600160a060020a038084169216907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a36003805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a03929092169190911790555600a165627a7a723058201e02c4dd21a9ac264dddd959d01ba19ca6b4d03d304450d483fc226e06d94cd20029",
"deployedBytecode": "0x6080604052600436106101065763ffffffff7c010000000000000000000000000000000000000000000000000000000060003504166305d2035b811461010b578063095ea7b3146101345780630c96d9e71461015857806318160ddd1461017f57806323b872dd146101945780632f6c493c146101be57806340c10f19146101e157806358fa9fe314610205578063661884631461022957806370a082311461024d578063715018a61461026e5780637d64bcb4146102835780638da5cb5b14610298578063a9059cbb146102c9578063cd5d1084146102ed578063d73dd6231461030e578063dd62ed3e14610332578063f2fde38b14610359578063f6c788b21461037a575b600080fd5b34801561011757600080fd5b5061012061039b565b604080519115158252519081900360200190f35b34801561014057600080fd5b50610120600160a060020a03600435166024356103bc565b34801561016457600080fd5b5061016d610423565b60408051918252519081900360200190f35b34801561018b57600080fd5b5061016d610429565b3480156101a057600080fd5b50610120600160a060020a036004358116906024351660443561042f565b3480156101ca57600080fd5b506101df600160a060020a03600435166104fa565b005b3480156101ed57600080fd5b50610120600160a060020a0360043516602435610509565b34801561021157600080fd5b506101df600160a060020a036004351660243561054f565b34801561023557600080fd5b50610120600160a060020a03600435166024356106bb565b34801561025957600080fd5b5061016d600160a060020a03600435166107aa565b34801561027a57600080fd5b506101df6107c5565b34801561028f57600080fd5b50610120610833565b3480156102a457600080fd5b506102ad6108d9565b60408051600160a060020a039092168252519081900360200190f35b3480156102d557600080fd5b50610120600160a060020a03600435166024356108e8565b3480156102f957600080fd5b5061016d600160a060020a03600435166109a8565b34801561031a57600080fd5b50610120600160a060020a03600435166024356109ba565b34801561033e57600080fd5b5061016d600160a060020a0360043581169060243516610a53565b34801561036557600080fd5b506101df600160a060020a0360043516610a7e565b34801561038657600080fd5b5061016d600160a060020a0360043516610a9e565b60035474010000000000000000000000000000000000000000900460ff1681565b336000818152600260209081526040808320600160a060020a038716808552908352818420869055815186815291519394909390927f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925928290030190a35060015b92915050565b60045481565b60015490565b600061043a846104fa565b600160a060020a03841660009081526006602090815260408083205491839052909120548391610470919063ffffffff610ab016565b10156104dd57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f4e6f7420656e6f7567682062616c616e63652e00000000000000000000000000604482015290519081900360640190fd5b6104e8848484610ac2565b15156104f057fe5b5060019392505050565b6105068160001961054f565b50565b6000610514836104fa565b61051e8383610c37565b151561052657fe5b600160a060020a0383166000908152600660205260409020546104f0908363ffffffff610d5216565b600160a060020a038216600090815260056020526040812054819081904290610581906224ea0063ffffffff610d5216565b111580156105a65750600160a060020a03851660009081526006602052604090205415155b156106b457600160a060020a0385166000908152600560205260409020546224ea00906105da90429063ffffffff610ab016565b8115156105e357fe5b0492508383106105f357836105f5565b825b925061063261060d846224ea0063ffffffff610d5f16565b600160a060020a0387166000908152600560205260409020549063ffffffff610d5216565b600160a060020a0386166000908152600560209081526040808320939093556006905290812054925090505b828110156106985761068e620f424061068260045485610d5f90919063ffffffff16565b9063ffffffff610d8816565b915060010161065e565b600160a060020a03851660009081526006602052604090208290555b5050505050565b336000908152600260209081526040808320600160a060020a038616845290915281205480831061070f57336000908152600260209081526040808320600160a060020a0388168452909152812055610744565b61071f818463ffffffff610ab016565b336000908152600260209081526040808320600160a060020a03891684529091529020555b336000818152600260209081526040808320600160a060020a0389168085529083529281902054815190815290519293927f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925929181900390910190a35060019392505050565b600160a060020a031660009081526020819052604090205490565b600354600160a060020a031633146107dc57600080fd5b600354604051600160a060020a03909116907ff8df31144d9c2f0f6b59d69b8b98abd5459d07f2742c4df920b25aae33c6482090600090a26003805473ffffffffffffffffffffffffffffffffffffffff19169055565b600354600090600160a060020a0316331461084d57600080fd5b60035474010000000000000000000000000000000000000000900460ff161561087557600080fd5b6003805474ff00000000000000000000000000000000000000001916740100000000000000000000000000000000000000001790556040517fae5184fba832cb2b1f702aca6117b8d265eaf03ad33eb133f19dde0f5920fa0890600090a150600190565b600354600160a060020a031681565b60006108f3336104fa565b3360009081526006602090815260408083205491839052909120548391610920919063ffffffff610ab016565b101561098d57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f4e6f7420656e6f7567682062616c616e63652e00000000000000000000000000604482015290519081900360640190fd5b6109978383610d9d565b151561099f57fe5b50600192915050565b60056020526000908152604090205481565b336000908152600260209081526040808320600160a060020a03861684529091528120546109ee908363ffffffff610d5216565b336000818152600260209081526040808320600160a060020a0389168085529083529281902085905580519485525191937f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925929081900390910190a350600192915050565b600160a060020a03918216600090815260026020908152604080832093909416825291909152205490565b600354600160a060020a03163314610a9557600080fd5b61050681610e7c565b60066020526000908152604090205481565b600082821115610abc57fe5b50900390565b600160a060020a038316600090815260208190526040812054821115610ae757600080fd5b600160a060020a0384166000908152600260209081526040808320338452909152902054821115610b1757600080fd5b600160a060020a0383161515610b2c57600080fd5b600160a060020a038416600090815260208190526040902054610b55908363ffffffff610ab016565b600160a060020a038086166000908152602081905260408082209390935590851681522054610b8a908363ffffffff610d5216565b600160a060020a03808516600090815260208181526040808320949094559187168152600282528281203382529091522054610bcc908363ffffffff610ab016565b600160a060020a03808616600081815260026020908152604080832033845282529182902094909455805186815290519287169391927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef929181900390910190a35060019392505050565b600354600090600160a060020a03163314610c5157600080fd5b60035474010000000000000000000000000000000000000000900460ff1615610c7957600080fd5b600154610c8c908363ffffffff610d5216565b600155600160a060020a038316600090815260208190526040902054610cb8908363ffffffff610d5216565b600160a060020a03841660008181526020818152604091829020939093558051858152905191927f0f6798a560793a54c3bcfe86a93cde1e73087d944c0ea20544137d412139688592918290030190a2604080518381529051600160a060020a038516916000917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9181900360200190a350600192915050565b8181018281101561041d57fe5b6000821515610d705750600061041d565b50818102818382811515610d8057fe5b041461041d57fe5b60008183811515610d9557fe5b049392505050565b33600090815260208190526040812054821115610db957600080fd5b600160a060020a0383161515610dce57600080fd5b33600090815260208190526040902054610dee908363ffffffff610ab016565b3360009081526020819052604080822092909255600160a060020a03851681522054610e20908363ffffffff610d5216565b600160a060020a038416600081815260208181526040918290209390935580518581529051919233927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9281900390910190a350600192915050565b600160a060020a0381161515610e9157600080fd5b600354604051600160a060020a038084169216907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a36003805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a03929092169190911790555600a165627a7a723058201e02c4dd21a9ac264dddd959d01ba19ca6b4d03d304450d483fc226e06d94cd20029",
"sourceMap": "525:3580:6:-;;;436:35:66;;;-1:-1:-1;;;;;;436:35:66;;;1199:144:6;5:2:-1;;;;30:1;27;20:12;5:2;1199:144:6;;;;;;;;;;;;;567:5:62;:18;;-1:-1:-1;;;;;;567:18:62;575:10;567:18;;;1268:32:6;:68;525:3580;;;;;;",
"deployedSourceMap": "525:3580:6:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;436:35:66;;8:9:-1;5:2;;;30:1;27;20:12;5:2;436:35:66;;;;;;;;;;;;;;;;;;;;;;1814:188:67;;8:9:-1;5:2;;;30:1;27;20:12;5:2;-1:-1;1814:188:67;-1:-1:-1;;;;;1814:188:67;;;;;;;569:44:6;;8:9:-1;5:2;;;30:1;27;20:12;5:2;569:44:6;;;;;;;;;;;;;;;;;;;;389:83:63;;8:9:-1;5:2;;;30:1;27;20:12;5:2;389:83:63;;;;3816:286:6;;8:9:-1;5:2;;;30:1;27;20:12;5:2;-1:-1;3816:286:6;-1:-1:-1;;;;;3816:286:6;;;;;;;;;;;;2163:80;;8:9:-1;5:2;;;30:1;27;20:12;5:2;-1:-1;2163:80:6;-1:-1:-1;;;;;2163:80:6;;;;;;;1578:196;;8:9:-1;5:2;;;30:1;27;20:12;5:2;-1:-1;1578:196:6;-1:-1:-1;;;;;1578:196:6;;;;;;;2433:660;;8:9:-1;5:2;;;30:1;27;20:12;5:2;-1:-1;2433:660:6;-1:-1:-1;;;;;2433:660:6;;;;;;;3679:432:67;;8:9:-1;5:2;;;30:1;27;20:12;5:2;-1:-1;3679:432:67;-1:-1:-1;;;;;3679:432:67;;;;;;;1149:99:63;;8:9:-1;5:2;;;30:1;27;20:12;5:2;-1:-1;1149:99:63;-1:-1:-1;;;;;1149:99:63;;;;;1001:111:62;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1001:111:62;;;;1280:140:66;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1280:140:66;;;;238:20:62;;8:9:-1;5:2;;;30:1;27;20:12;5:2;238:20:62;;;;;;;;-1:-1:-1;;;;;238:20:62;;;;;;;;;;;;;;3259:272:6;;8:9:-1;5:2;;;30:1;27;20:12;5:2;-1:-1;3259:272:6;-1:-1:-1;;;;;3259:272:6;;;;;;;719:43;;8:9:-1;5:2;;;30:1;27;20:12;5:2;-1:-1;719:43:6;-1:-1:-1;;;;;719:43:6;;;;;2926:296:67;;8:9:-1;5:2;;;30:1;27;20:12;5:2;-1:-1;2926:296:67;-1:-1:-1;;;;;2926:296:67;;;;;;;2321:153;;8:9:-1;5:2;;;30:1;27;20:12;5:2;-1:-1;2321:153:67;-1:-1:-1;;;;;2321:153:67;;;;;;;;;;1274:103:62;;8:9:-1;5:2;;;30:1;27;20:12;5:2;-1:-1;1274:103:62;-1:-1:-1;;;;;1274:103:62;;;;;803:45:6;;8:9:-1;5:2;;;30:1;27;20:12;5:2;-1:-1;803:45:6;-1:-1:-1;;;;;803:45:6;;;;;436:35:66;;;;;;;;;:::o;1814:188:67:-;1901:10;1881:4;1893:19;;;:7;:19;;;;;;;;-1:-1:-1;;;;;1893:29:67;;;;;;;;;;;:38;;;1942;;;;;;;1881:4;;1893:29;;1901:10;;1942:38;;;;;;;;-1:-1:-1;1993:4:67;1814:188;;;;;:::o;569:44:6:-;;;;:::o;389:83:63:-;455:12;;389:83;:::o;3816:286:6:-;3898:4;3914:13;3921:5;3914:6;:13::i;:::-;-1:-1:-1;;;;;3965:19:6;;;;;;:12;:19;;;;;;;;;3945:15;;;;;;;;3989:6;;3945:40;;:15;:40;:19;:40;:::i;:::-;:50;;3937:82;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4037:36;4056:5;4062:3;4066:6;4037:18;:36::i;:::-;4030:44;;;;;;-1:-1:-1;4091:4:6;3816:286;;;;;:::o;2163:80::-;2209:27;2223:3;-1:-1:-1;;2209:13:6;:27::i;:::-;2163:80;:::o;1578:196::-;1638:4;1654:11;1661:3;1654:6;:11::i;:::-;1682:23;1693:3;1697:7;1682:10;:23::i;:::-;1675:31;;;;;;-1:-1:-1;;;;;1716:17:6;;;;;;:12;:17;;;;;;:30;;1738:7;1716:30;:21;:30;:::i;2433:660::-;-1:-1:-1;;;;;2507:15:6;;2582:19;2507:15;;;:10;:15;;;;;;2582:19;;;;2539:3;;2507:28;;2527:7;2507:28;:19;:28;:::i;:::-;:35;;:59;;;;-1:-1:-1;;;;;;2546:17:6;;;;;;:12;:17;;;;;;:20;;2507:59;2503:584;;;-1:-1:-1;;;;;2612:15:6;;;;;;:10;:15;;;;;;2632:7;;2604:24;;:3;;:24;:7;:24;:::i;:::-;:36;;;;;;;;2582:58;;2688:10;2671:14;:27;:57;;2718:10;2671:57;;;2701:14;2671:57;2654:74;-1:-1:-1;2760:48:6;2780:27;2654:74;2799:7;2780:27;:18;:27;:::i;:::-;-1:-1:-1;;;;;2760:15:6;;;;;;:10;:15;;;;;;;:48;:19;:48;:::i;:::-;-1:-1:-1;;;;;2742:15:6;;;;;;:10;:15;;;;;;;;:66;;;;2867:12;:17;;;;;;;-1:-1:-1;2742:15:6;-1:-1:-1;2898:135:6;2919:14;2915:1;:18;2898:135;;;2968:65;710:3;2968:47;2982:32;;2968:9;:13;;:47;;;;:::i;:::-;:51;:65;:51;:65;:::i;:::-;2956:77;-1:-1:-1;2935:3:6;;2898:135;;;-1:-1:-1;;;;;3047:17:6;;;;;;:12;:17;;;;;:29;;;2503:584;2433:660;;;;;:::o;3679:432:67:-;3826:10;3785:4;3818:19;;;:7;:19;;;;;;;;-1:-1:-1;;;;;3818:29:67;;;;;;;;;;3857:28;;;3853:165;;3903:10;3927:1;3895:19;;;:7;:19;;;;;;;;-1:-1:-1;;;;;3895:29:67;;;;;;;;;:33;3853:165;;;3981:30;:8;3994:16;3981:30;:12;:30;:::i;:::-;3957:10;3949:19;;;;:7;:19;;;;;;;;-1:-1:-1;;;;;3949:29:67;;;;;;;;;:62;3853:165;4037:10;4059:19;;;;:7;:19;;;;;;;;-1:-1:-1;;;;;4028:61:67;;4059:29;;;;;;;;;;;4028:61;;;;;;;;;4037:10;4028:61;;;;;;;;;;;-1:-1:-1;4102:4:67;;3679:432;-1:-1:-1;;;3679:432:67:o;1149:99:63:-;-1:-1:-1;;;;;1227:16:63;1205:7;1227:16;;;;;;;;;;;;1149:99::o;1001:111:62:-;719:5;;-1:-1:-1;;;;;719:5:62;705:10;:19;697:28;;;;;;1077:5;;1058:25;;-1:-1:-1;;;;;1077:5:62;;;;1058:25;;1077:5;;1058:25;1089:5;:18;;-1:-1:-1;;1089:18:62;;;1001:111::o;1280:140:66:-;719:5:62;;1339:4:66;;-1:-1:-1;;;;;719:5:62;705:10;:19;697:28;;;;;;511:15:66;;;;;;;510:16;502:25;;;;;;1351:15;:22;;-1:-1:-1;;1351:22:66;;;;;1384:14;;;;1351:22;;1384:14;-1:-1:-1;1411:4:66;1280:140;:::o;238:20:62:-;;;-1:-1:-1;;;;;238:20:62;;:::o;3259:272:6:-;3322:4;3338:18;3345:10;3338:6;:18::i;:::-;3412:10;3399:24;;;;:12;:24;;;;;;;;;3374:20;;;;;;;;3428:6;;3374:50;;:20;:50;:24;:50;:::i;:::-;:60;;3366:92;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3476:26;3491:3;3495:6;3476:14;:26::i;:::-;3469:34;;;;;;-1:-1:-1;3520:4:6;3259:272;;;;:::o;719:43::-;;;;;;;;;;;;;:::o;2926:296:67:-;3089:10;3027:4;3081:19;;;:7;:19;;;;;;;;-1:-1:-1;;;;;3081:29:67;;;;;;;;;;:46;;3115:11;3081:46;:33;:46;:::i;:::-;3049:10;3041:19;;;;:7;:19;;;;;;;;-1:-1:-1;;;;;3041:29:67;;;;;;;;;;;;:87;;;3139:61;;;;;;3041:29;;3139:61;;;;;;;;;;;-1:-1:-1;3213:4:67;2926:296;;;;:::o;2321:153::-;-1:-1:-1;;;;;2444:15:67;;;2420:7;2444:15;;;:7;:15;;;;;;;;:25;;;;;;;;;;;;;2321:153::o;1274:103:62:-;719:5;;-1:-1:-1;;;;;719:5:62;705:10;:19;697:28;;;;;;1343:29;1362:9;1343:18;:29::i;803:45:6:-;;;;;;;;;;;;;:::o;1060:116:61:-;1120:7;1142:8;;;;1135:16;;;;-1:-1:-1;1164:7:61;;;1060:116::o;726:470:67:-;-1:-1:-1;;;;;864:15:67;;832:4;864:15;;;;;;;;;;;854:25;;;846:34;;;;;;-1:-1:-1;;;;;904:14:67;;;;;;:7;:14;;;;;;;;919:10;904:26;;;;;;;;894:36;;;886:45;;;;;;-1:-1:-1;;;;;945:17:67;;;;937:26;;;;;;-1:-1:-1;;;;;988:15:67;;:8;:15;;;;;;;;;;;:27;;1008:6;988:27;:19;:27;:::i;:::-;-1:-1:-1;;;;;970:15:67;;;:8;:15;;;;;;;;;;;:45;;;;1037:13;;;;;;;:25;;1055:6;1037:25;:17;:25;:::i;:::-;-1:-1:-1;;;;;1021:13:67;;;:8;:13;;;;;;;;;;;:41;;;;1097:14;;;;;:7;:14;;;;;1112:10;1097:26;;;;;;;:38;;1128:6;1097:38;:30;:38;:::i;:::-;-1:-1:-1;;;;;1068:14:67;;;;;;;:7;:14;;;;;;;;1083:10;1068:26;;;;;;;;:67;;;;1146:28;;;;;;;;;;;1068:14;;1146:28;;;;;;;;;;;-1:-1:-1;1187:4:67;726:470;;;;;:::o;854:312:66:-;600:5;;968:4;;-1:-1:-1;;;;;600:5:66;586:10;:19;578:28;;;;;;511:15;;;;;;;510:16;502:25;;;;;;997:12;;:25;;1014:7;997:25;:16;:25;:::i;:::-;982:12;:40;-1:-1:-1;;;;;1044:13:66;;:8;:13;;;;;;;;;;;:26;;1062:7;1044:26;:17;:26;:::i;:::-;-1:-1:-1;;;;;1028:13:66;;:8;:13;;;;;;;;;;;;:42;;;;1081:18;;;;;;;1028:13;;1081:18;;;;;;;;;1110:34;;;;;;;;-1:-1:-1;;;;;1110:34:66;;;1127:1;;1110:34;;;;;;;;;-1:-1:-1;1157:4:66;854:312;;;;:::o;1238:128:61:-;1319:7;;;1339;;;;1332:15;;;203:380;263:9;489:7;;485:36;;;-1:-1:-1;513:1:61;506:8;;485:36;-1:-1:-1;531:7:61;;;536:2;531;:7;551:6;;;;;;;;:12;544:20;;;665:283;725:7;941:2;936;:7;;;;;;;;;665:283;-1:-1:-1;;;665:283:61:o;626:321:63:-;728:10;689:4;719:20;;;;;;;;;;;709:30;;;701:39;;;;;;-1:-1:-1;;;;;754:17:63;;;;746:26;;;;;;811:10;802:8;:20;;;;;;;;;;;:32;;827:6;802:32;:24;:32;:::i;:::-;788:10;779:8;:20;;;;;;;;;;;:55;;;;-1:-1:-1;;;;;856:13:63;;;;;;:25;;874:6;856:25;:17;:25;:::i;:::-;-1:-1:-1;;;;;840:13:63;;:8;:13;;;;;;;;;;;;:41;;;;892:33;;;;;;;840:13;;901:10;;892:33;;;;;;;;;;-1:-1:-1;938:4:63;626:321;;;;:::o;1512:171:62:-;-1:-1:-1;;;;;1582:23:62;;;;1574:32;;;;;;1638:5;;1617:38;;-1:-1:-1;;;;;1617:38:62;;;;1638:5;;1617:38;;1638:5;;1617:38;1661:5;:17;;-1:-1:-1;;1661:17:62;-1:-1:-1;;;;;1661:17:62;;;;;;;;;;1512:171::o",
"source": "/**\n * @title Locked Token\n * @author Clément Lesaege - <clement@lesaege.com>\n * Bug Bounties: This code hasn't undertaken a bug bounty program yet.\n */\n\n\npragma solidity ^0.4.15;\nimport \"openzeppelin-solidity/contracts/token/ERC20/MintableToken.sol\";\n\n\n/** @title Locked Token\n * @dev A token when created coins are locked and unlock accross time.\n * Note that we use steps for one month. In the future, when float are available, we could use law of exponential decay to avoid steps and have a smoothed unlocking.\n */\ncontract LockedToken is MintableToken {\n uint public lockMultiplierPerMillionPerMonth; // The amount we must multiply the locked balance each month.\n uint constant LOCK_DIVISOR = 1E6;\n mapping (address => uint) public lastUnlock; // Last time tokens were unlocked.\n mapping (address => uint) public amountLocked; // The amount of tokens locked.\n\n /** @dev Constructor.\n * @param _lockMultiplierPerMillionPerMonth The amount we must multiply the locked portion each month.\n * It is (1-unlockRatioPerYear)^(1/12) * 1E6. Note that we should compute that offchain to avoid integer rounding.\n * So for 10% unlock per year, it is 991258.\n */\n constructor(uint _lockMultiplierPerMillionPerMonth) public {\n lockMultiplierPerMillionPerMonth = _lockMultiplierPerMillionPerMonth;\n }\n\n /** @dev Mint tokens.\n * @param _to The address that will receive the minted tokens.\n * @param _amount The amount of tokens to mint.\n * @return A boolean that indicates if the operation was successful.\n */\n function mint(address _to, uint256 _amount) public returns (bool) {\n unlock(_to);\n assert(super.mint(_to,_amount));\n amountLocked[_to].add(_amount);\n return true;\n }\n\n /** @dev Unlock the tokens which can.\n * Note that this function is O(log(t)) where t is the last time of unlock.\n * You can call partiallUnlock with a maxUnlock to avoid gas issues.\n * But note that it is likely to never be necessary as the cost of this function, if not high even for multiple years.\n * @param _to The address to unlock tokens from.\n */\n function unlock(address _to) public {\n partialUnlock(_to,uint(-1));\n }\n\n /** @dev Unlock the tokens which can.\n * This function is O(_maxUnlock). You may need to call it multiple times.\n * @param _to The address to unlock tokens from.\n */\n function partialUnlock(address _to, uint _maxUnlock) public {\n if (lastUnlock[_to].add(4 weeks) <= now && amountLocked[_to]!=0) {\n uint amountOfMonths = now.sub(lastUnlock[_to]) / (4 weeks);\n amountOfMonths = amountOfMonths < _maxUnlock ? amountOfMonths : _maxUnlock;\n lastUnlock[_to] = lastUnlock[_to].add(amountOfMonths.mul(4 weeks)); // Update last unlock date.\n uint newLocked = amountLocked[_to];\n for (uint i = 0; i < amountOfMonths; ++i)\n newLocked = newLocked.mul(lockMultiplierPerMillionPerMonth).div(LOCK_DIVISOR);\n amountLocked[_to] = newLocked;\n }\n }\n\n /** @dev Transfer token for a specified address.\n * @param _to The address to transfer to.\n * @param _value The amount to be transferred.\n */\n function transfer(address _to, uint256 _value) public returns (bool) {\n unlock(msg.sender);\n require(balances[msg.sender].sub(amountLocked[msg.sender]) >= _value, \"Not enough balance.\");\n\n assert(super.transfer(_to,_value));\n return true;\n }\n\n /** @dev Transfer tokens from one address to another\n * @param _from address The address which you want to send tokens from\n * @param _to address The address which you want to transfer to\n * @param _value uint256 the amount of tokens to be transferred\n */\n function transferFrom(address _from, address _to, uint256 _value) public returns (bool) {\n unlock(_from);\n require(balances[_from].sub(amountLocked[_from]) >= _value, \"Not enough balance.\");\n\n assert(super.transferFrom(_from,_to,_value));\n return true;\n }\n\n}\n",
"sourcePath": "/private/tmp/kleros-interaction/contracts/standard/arbitration/ArbitrableTokens/LockedToken.sol",
"ast": {
"absolutePath": "/private/tmp/kleros-interaction/contracts/standard/arbitration/ArbitrableTokens/LockedToken.sol",
"exportedSymbols": {
"LockedToken": [
3682
]
},
"id": 3683,
"nodeType": "SourceUnit",
"nodes": [
{
"id": 3436,
"literals": [
"solidity",
"^",
"0.4",
".15"
],
"nodeType": "PragmaDirective",
"src": "159:24:6"
},
{
"absolutePath": "openzeppelin-solidity/contracts/token/ERC20/MintableToken.sol",
"file": "openzeppelin-solidity/contracts/token/ERC20/MintableToken.sol",
"id": 3437,
"nodeType": "ImportDirective",
"scope": 3683,
"sourceUnit": 20210,
"src": "184:71:6",
"symbolAliases": [],
"unitAlias": ""
},
{
"baseContracts": [
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 3438,
"name": "MintableToken",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 20209,
"src": "549:13:6",
"typeDescriptions": {
"typeIdentifier": "t_contract$_MintableToken_$20209",
"typeString": "contract MintableToken"
}
},
"id": 3439,
"nodeType": "InheritanceSpecifier",
"src": "549:13:6"
}
],
"contractDependencies": [
19932,
20028,
20071,
20103,
20209,
20456
],
"contractKind": "contract",
"documentation": "@title Locked Token\n @dev A token when created coins are locked and unlock accross time.\n Note that we use steps for one month. In the future, when float are available, we could use law of exponential decay to avoid steps and have a smoothed unlocking.",
"fullyImplemented": true,
"id": 3682,
"linearizedBaseContracts": [
3682,
20209,
19932,
20456,
20028,
20071,
20103
],
"name": "LockedToken",
"nodeType": "ContractDefinition",
"nodes": [
{
"constant": false,
"id": 3441,
"name": "lockMultiplierPerMillionPerMonth",
"nodeType": "VariableDeclaration",
"scope": 3682,
"src": "569:44:6",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3440,
"name": "uint",
"nodeType": "ElementaryTypeName",
"src": "569:4:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "public"
},
{
"constant": true,
"id": 3444,
"name": "LOCK_DIVISOR",
"nodeType": "VariableDeclaration",
"scope": 3682,
"src": "681:32:6",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3442,
"name": "uint",
"nodeType": "ElementaryTypeName",
"src": "681:4:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": {
"argumentTypes": null,
"hexValue": "314536",
"id": 3443,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "710:3:6",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_1000000_by_1",
"typeString": "int_const 1000000"
},
"value": "1E6"
},
"visibility": "internal"
},
{
"constant": false,
"id": 3448,
"name": "lastUnlock",
"nodeType": "VariableDeclaration",
"scope": 3682,
"src": "719:43:6",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
},
"typeName": {
"id": 3447,
"keyType": {
"id": 3445,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "728:7:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "Mapping",
"src": "719:25:6",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
},
"valueType": {
"id": 3446,
"name": "uint",
"nodeType": "ElementaryTypeName",
"src": "739:4:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
},
"value": null,
"visibility": "public"
},
{
"constant": false,
"id": 3452,
"name": "amountLocked",
"nodeType": "VariableDeclaration",
"scope": 3682,
"src": "803:45:6",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
},
"typeName": {
"id": 3451,
"keyType": {
"id": 3449,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "812:7:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "Mapping",
"src": "803:25:6",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
},
"valueType": {
"id": 3450,
"name": "uint",
"nodeType": "ElementaryTypeName",
"src": "823:4:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
},
"value": null,
"visibility": "public"
},
{
"body": {
"id": 3461,
"nodeType": "Block",
"src": "1258:85:6",
"statements": [
{
"expression": {
"argumentTypes": null,
"id": 3459,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"id": 3457,
"name": "lockMultiplierPerMillionPerMonth",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3441,
"src": "1268:32:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"id": 3458,
"name": "_lockMultiplierPerMillionPerMonth",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3454,
"src": "1303:33:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "1268:68:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3460,
"nodeType": "ExpressionStatement",
"src": "1268:68:6"
}
]
},
"documentation": "@dev Constructor.\n @param _lockMultiplierPerMillionPerMonth The amount we must multiply the locked portion each month.\n It is (1-unlockRatioPerYear)^(1/12) * 1E6. Note that we should compute that offchain to avoid integer rounding.\n So for 10% unlock per year, it is 991258.",
"id": 3462,
"implemented": true,
"isConstructor": true,
"isDeclaredConst": false,
"modifiers": [],
"name": "",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 3455,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3454,
"name": "_lockMultiplierPerMillionPerMonth",
"nodeType": "VariableDeclaration",
"scope": 3462,
"src": "1211:38:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3453,
"name": "uint",
"nodeType": "ElementaryTypeName",
"src": "1211:4:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "1210:40:6"
},
"payable": false,
"returnParameters": {
"id": 3456,
"nodeType": "ParameterList",
"parameters": [],
"src": "1258:0:6"
},
"scope": 3682,
"src": "1199:144:6",
"stateMutability": "nonpayable",
"superFunction": null,
"visibility": "public"
},
{
"body": {
"id": 3492,
"nodeType": "Block",
"src": "1644:130:6",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3472,
"name": "_to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3464,
"src": "1661:3:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 3471,
"name": "unlock",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3507,
"src": "1654:6:6",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 3473,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "1654:11:6",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3474,
"nodeType": "ExpressionStatement",
"src": "1654:11:6"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3478,
"name": "_to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3464,
"src": "1693:3:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 3479,
"name": "_amount",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3466,
"src": "1697:7:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"id": 3476,
"name": "super",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20723,
"src": "1682:5:6",
"typeDescriptions": {
"typeIdentifier": "t_super$_LockedToken_$3682",
"typeString": "contract super LockedToken"
}
},
"id": 3477,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "mint",
"nodeType": "MemberAccess",
"referencedDeclaration": 20189,
"src": "1682:10:6",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$",
"typeString": "function (address,uint256) returns (bool)"
}
},
"id": 3480,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "1682:23:6",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 3475,
"name": "assert",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20628,
"src": "1675:6:6",
"typeDescriptions": {
"typeIdentifier": "t_function_assert_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 3481,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "1675:31:6",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3482,
"nodeType": "ExpressionStatement",
"src": "1675:31:6"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3487,
"name": "_amount",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3466,
"src": "1738:7:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3483,
"name": "amountLocked",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3452,
"src": "1716:12:6",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
}
},
"id": 3485,
"indexExpression": {
"argumentTypes": null,
"id": 3484,
"name": "_to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3464,
"src": "1729:3:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "1716:17:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3486,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "add",
"nodeType": "MemberAccess",
"referencedDeclaration": 19845,
"src": "1716:21:6",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
"typeString": "function (uint256,uint256) pure returns (uint256)"
}
},
"id": 3488,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "1716:30:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3489,
"nodeType": "ExpressionStatement",
"src": "1716:30:6"
},
{
"expression": {
"argumentTypes": null,
"hexValue": "74727565",
"id": 3490,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "bool",
"lValueRequested": false,
"nodeType": "Literal",
"src": "1763:4:6",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"value": "true"
},
"functionReturnParameters": 3470,
"id": 3491,
"nodeType": "Return",
"src": "1756:11:6"
}
]
},
"documentation": "@dev Mint tokens.\n @param _to The address that will receive the minted tokens.\n @param _amount The amount of tokens to mint.\n @return A boolean that indicates if the operation was successful.",
"id": 3493,
"implemented": true,
"isConstructor": false,
"isDeclaredConst": false,
"modifiers": [],
"name": "mint",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 3467,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3464,
"name": "_to",
"nodeType": "VariableDeclaration",
"scope": 3493,
"src": "1592:11:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3463,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "1592:7:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 3466,
"name": "_amount",
"nodeType": "VariableDeclaration",
"scope": 3493,
"src": "1605:15:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3465,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "1605:7:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "1591:30:6"
},
"payable": false,
"returnParameters": {
"id": 3470,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3469,
"name": "",
"nodeType": "VariableDeclaration",
"scope": 3493,
"src": "1638:4:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 3468,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "1638:4:6",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "1637:6:6"
},
"scope": 3682,
"src": "1578:196:6",
"stateMutability": "nonpayable",
"superFunction": 20189,
"visibility": "public"
},
{
"body": {
"id": 3506,
"nodeType": "Block",
"src": "2199:44:6",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3499,
"name": "_to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3495,
"src": "2223:3:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3502,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "UnaryOperation",
"operator": "-",
"prefix": true,
"src": "2232:2:6",
"subExpression": {
"argumentTypes": null,
"hexValue": "31",
"id": 3501,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "2233:1:6",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_1_by_1",
"typeString": "int_const 1"
},
"value": "1"
},
"typeDescriptions": {
"typeIdentifier": "t_rational_-1_by_1",
"typeString": "int_const -1"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_rational_-1_by_1",
"typeString": "int_const -1"
}
],
"id": 3500,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "2227:4:6",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_uint256_$",
"typeString": "type(uint256)"
},
"typeName": "uint"
},
"id": 3503,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "2227:8:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"id": 3498,
"name": "partialUnlock",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3599,
"src": "2209:13:6",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$__$",
"typeString": "function (address,uint256)"
}
},
"id": 3504,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "2209:27:6",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3505,
"nodeType": "ExpressionStatement",
"src": "2209:27:6"
}
]
},
"documentation": "@dev Unlock the tokens which can.\n Note that this function is O(log(t)) where t is the last time of unlock.\n You can call partiallUnlock with a maxUnlock to avoid gas issues.\n But note that it is likely to never be necessary as the cost of this function, if not high even for multiple years.\n @param _to The address to unlock tokens from.",
"id": 3507,
"implemented": true,
"isConstructor": false,
"isDeclaredConst": false,
"modifiers": [],
"name": "unlock",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 3496,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3495,
"name": "_to",
"nodeType": "VariableDeclaration",
"scope": 3507,
"src": "2179:11:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3494,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "2179:7:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "2178:13:6"
},
"payable": false,
"returnParameters": {
"id": 3497,
"nodeType": "ParameterList",
"parameters": [],
"src": "2199:0:6"
},
"scope": 3682,
"src": "2163:80:6",
"stateMutability": "nonpayable",
"superFunction": null,
"visibility": "public"
},
{
"body": {
"id": 3598,
"nodeType": "Block",
"src": "2493:600:6",
"statements": [
{
"condition": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"id": 3527,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 3521,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "34",
"id": 3518,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "2527:7:6",
"subdenomination": "weeks",
"typeDescriptions": {
"typeIdentifier": "t_rational_2419200_by_1",
"typeString": "int_const 2419200"
},
"value": "4"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_rational_2419200_by_1",
"typeString": "int_const 2419200"
}
],
"expression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3514,
"name": "lastUnlock",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3448,
"src": "2507:10:6",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
}
},
"id": 3516,
"indexExpression": {
"argumentTypes": null,
"id": 3515,
"name": "_to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3509,
"src": "2518:3:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "2507:15:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3517,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "add",
"nodeType": "MemberAccess",
"referencedDeclaration": 19845,
"src": "2507:19:6",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
"typeString": "function (uint256,uint256) pure returns (uint256)"
}
},
"id": 3519,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "2507:28:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "<=",
"rightExpression": {
"argumentTypes": null,
"id": 3520,
"name": "now",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20641,
"src": "2539:3:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "2507:35:6",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"nodeType": "BinaryOperation",
"operator": "&&",
"rightExpression": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 3526,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3522,
"name": "amountLocked",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3452,
"src": "2546:12:6",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
}
},
"id": 3524,
"indexExpression": {
"argumentTypes": null,
"id": 3523,
"name": "_to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3509,
"src": "2559:3:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "2546:17:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "!=",
"rightExpression": {
"argumentTypes": null,
"hexValue": "30",
"id": 3525,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "2565:1:6",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
},
"src": "2546:20:6",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"src": "2507:59:6",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"falseBody": null,
"id": 3597,
"nodeType": "IfStatement",
"src": "2503:584:6",
"trueBody": {
"id": 3596,
"nodeType": "Block",
"src": "2568:519:6",
"statements": [
{
"assignments": [
3529
],
"declarations": [
{
"constant": false,
"id": 3529,
"name": "amountOfMonths",
"nodeType": "VariableDeclaration",
"scope": 3599,
"src": "2582:19:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3528,
"name": "uint",
"nodeType": "ElementaryTypeName",
"src": "2582:4:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 3539,
"initialValue": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 3538,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3532,
"name": "lastUnlock",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3448,
"src": "2612:10:6",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
}
},
"id": 3534,
"indexExpression": {
"argumentTypes": null,
"id": 3533,
"name": "_to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3509,
"src": "2623:3:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "2612:15:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"id": 3530,
"name": "now",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20641,
"src": "2604:3:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3531,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sub",
"nodeType": "MemberAccess",
"referencedDeclaration": 19821,
"src": "2604:7:6",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
"typeString": "function (uint256,uint256) pure returns (uint256)"
}
},
"id": 3535,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "2604:24:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "/",
"rightExpression": {
"argumentTypes": null,
"components": [
{
"argumentTypes": null,
"hexValue": "34",
"id": 3536,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "2632:7:6",
"subdenomination": "weeks",
"typeDescriptions": {
"typeIdentifier": "t_rational_2419200_by_1",
"typeString": "int_const 2419200"
},
"value": "4"
}
],
"id": 3537,
"isConstant": false,
"isInlineArray": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "TupleExpression",
"src": "2631:9:6",
"typeDescriptions": {
"typeIdentifier": "t_rational_2419200_by_1",
"typeString": "int_const 2419200"
}
},
"src": "2604:36:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "2582:58:6"
},
{
"expression": {
"argumentTypes": null,
"id": 3547,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"id": 3540,
"name": "amountOfMonths",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3529,
"src": "2654:14:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"condition": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 3543,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 3541,
"name": "amountOfMonths",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3529,
"src": "2671:14:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "<",
"rightExpression": {
"argumentTypes": null,
"id": 3542,
"name": "_maxUnlock",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3511,
"src": "2688:10:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "2671:27:6",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"falseExpression": {
"argumentTypes": null,
"id": 3545,
"name": "_maxUnlock",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3511,
"src": "2718:10:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3546,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"nodeType": "Conditional",
"src": "2671:57:6",
"trueExpression": {
"argumentTypes": null,
"id": 3544,
"name": "amountOfMonths",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3529,
"src": "2701:14:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "2654:74:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3548,
"nodeType": "ExpressionStatement",
"src": "2654:74:6"
},
{
"expression": {
"argumentTypes": null,
"id": 3561,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3549,
"name": "lastUnlock",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3448,
"src": "2742:10:6",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
}
},
"id": 3551,
"indexExpression": {
"argumentTypes": null,
"id": 3550,
"name": "_to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3509,
"src": "2753:3:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "2742:15:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "34",
"id": 3558,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "2799:7:6",
"subdenomination": "weeks",
"typeDescriptions": {
"typeIdentifier": "t_rational_2419200_by_1",
"typeString": "int_const 2419200"
},
"value": "4"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_rational_2419200_by_1",
"typeString": "int_const 2419200"
}
],
"expression": {
"argumentTypes": null,
"id": 3556,
"name": "amountOfMonths",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3529,
"src": "2780:14:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3557,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "mul",
"nodeType": "MemberAccess",
"referencedDeclaration": 19787,
"src": "2780:18:6",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
"typeString": "function (uint256,uint256) pure returns (uint256)"
}
},
"id": 3559,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "2780:27:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3552,
"name": "lastUnlock",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3448,
"src": "2760:10:6",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
}
},
"id": 3554,
"indexExpression": {
"argumentTypes": null,
"id": 3553,
"name": "_to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3509,
"src": "2771:3:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "2760:15:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3555,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "add",
"nodeType": "MemberAccess",
"referencedDeclaration": 19845,
"src": "2760:19:6",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
"typeString": "function (uint256,uint256) pure returns (uint256)"
}
},
"id": 3560,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "2760:48:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "2742:66:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3562,
"nodeType": "ExpressionStatement",
"src": "2742:66:6"
},
{
"assignments": [
3564
],
"declarations": [
{
"constant": false,
"id": 3564,
"name": "newLocked",
"nodeType": "VariableDeclaration",
"scope": 3599,
"src": "2850:14:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3563,
"name": "uint",
"nodeType": "ElementaryTypeName",
"src": "2850:4:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 3568,
"initialValue": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3565,
"name": "amountLocked",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3452,
"src": "2867:12:6",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
}
},
"id": 3567,
"indexExpression": {
"argumentTypes": null,
"id": 3566,
"name": "_to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3509,
"src": "2880:3:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "2867:17:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "2850:34:6"
},
{
"body": {
"expression": {
"argumentTypes": null,
"id": 3587,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"id": 3579,
"name": "newLocked",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3564,
"src": "2956:9:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3585,
"name": "LOCK_DIVISOR",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3444,
"src": "3020:12:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3582,
"name": "lockMultiplierPerMillionPerMonth",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3441,
"src": "2982:32:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"id": 3580,
"name": "newLocked",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3564,
"src": "2968:9:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3581,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "mul",
"nodeType": "MemberAccess",
"referencedDeclaration": 19787,
"src": "2968:13:6",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
"typeString": "function (uint256,uint256) pure returns (uint256)"
}
},
"id": 3583,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "2968:47:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3584,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "div",
"nodeType": "MemberAccess",
"referencedDeclaration": 19801,
"src": "2968:51:6",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
"typeString": "function (uint256,uint256) pure returns (uint256)"
}
},
"id": 3586,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "2968:65:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "2956:77:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3588,
"nodeType": "ExpressionStatement",
"src": "2956:77:6"
},
"condition": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 3575,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 3573,
"name": "i",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3570,
"src": "2915:1:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "<",
"rightExpression": {
"argumentTypes": null,
"id": 3574,
"name": "amountOfMonths",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3529,
"src": "2919:14:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "2915:18:6",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"id": 3589,
"initializationExpression": {
"assignments": [
3570
],
"declarations": [
{
"constant": false,
"id": 3570,
"name": "i",
"nodeType": "VariableDeclaration",
"scope": 3599,
"src": "2903:6:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3569,
"name": "uint",
"nodeType": "ElementaryTypeName",
"src": "2903:4:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 3572,
"initialValue": {
"argumentTypes": null,
"hexValue": "30",
"id": 3571,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "2912:1:6",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
},
"nodeType": "VariableDeclarationStatement",
"src": "2903:10:6"
},
"loopExpression": {
"expression": {
"argumentTypes": null,
"id": 3577,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"nodeType": "UnaryOperation",
"operator": "++",
"prefix": true,
"src": "2935:3:6",
"subExpression": {
"argumentTypes": null,
"id": 3576,
"name": "i",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3570,
"src": "2937:1:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3578,
"nodeType": "ExpressionStatement",
"src": "2935:3:6"
},
"nodeType": "ForStatement",
"src": "2898:135:6"
},
{
"expression": {
"argumentTypes": null,
"id": 3594,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3590,
"name": "amountLocked",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3452,
"src": "3047:12:6",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
}
},
"id": 3592,
"indexExpression": {
"argumentTypes": null,
"id": 3591,
"name": "_to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3509,
"src": "3060:3:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "3047:17:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"id": 3593,
"name": "newLocked",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3564,
"src": "3067:9:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "3047:29:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3595,
"nodeType": "ExpressionStatement",
"src": "3047:29:6"
}
]
}
}
]
},
"documentation": "@dev Unlock the tokens which can.\n This function is O(_maxUnlock). You may need to call it multiple times.\n @param _to The address to unlock tokens from.",
"id": 3599,
"implemented": true,
"isConstructor": false,
"isDeclaredConst": false,
"modifiers": [],
"name": "partialUnlock",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 3512,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3509,
"name": "_to",
"nodeType": "VariableDeclaration",
"scope": 3599,
"src": "2456:11:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3508,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "2456:7:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 3511,
"name": "_maxUnlock",
"nodeType": "VariableDeclaration",
"scope": 3599,
"src": "2469:15:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3510,
"name": "uint",
"nodeType": "ElementaryTypeName",
"src": "2469:4:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "2455:30:6"
},
"payable": false,
"returnParameters": {
"id": 3513,
"nodeType": "ParameterList",
"parameters": [],
"src": "2493:0:6"
},
"scope": 3682,
"src": "2433:660:6",
"stateMutability": "nonpayable",
"superFunction": null,
"visibility": "public"
},
{
"body": {
"id": 3639,
"nodeType": "Block",
"src": "3328:203:6",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 3609,
"name": "msg",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20639,
"src": "3345:3:6",
"typeDescriptions": {
"typeIdentifier": "t_magic_message",
"typeString": "msg"
}
},
"id": 3610,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sender",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "3345:10:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 3608,
"name": "unlock",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3507,
"src": "3338:6:6",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 3611,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "3338:18:6",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3612,
"nodeType": "ExpressionStatement",
"src": "3338:18:6"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 3625,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3619,
"name": "amountLocked",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3452,
"src": "3399:12:6",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
}
},
"id": 3622,
"indexExpression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 3620,
"name": "msg",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20639,
"src": "3412:3:6",
"typeDescriptions": {
"typeIdentifier": "t_magic_message",
"typeString": "msg"
}
},
"id": 3621,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sender",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "3412:10:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "3399:24:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3614,
"name": "balances",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 19945,
"src": "3374:8:6",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
}
},
"id": 3617,
"indexExpression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 3615,
"name": "msg",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20639,
"src": "3383:3:6",
"typeDescriptions": {
"typeIdentifier": "t_magic_message",
"typeString": "msg"
}
},
"id": 3616,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sender",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "3383:10:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "3374:20:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3618,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sub",
"nodeType": "MemberAccess",
"referencedDeclaration": 19821,
"src": "3374:24:6",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
"typeString": "function (uint256,uint256) pure returns (uint256)"
}
},
"id": 3623,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "3374:50:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": ">=",
"rightExpression": {
"argumentTypes": null,
"id": 3624,
"name": "_value",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3603,
"src": "3428:6:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "3374:60:6",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "4e6f7420656e6f7567682062616c616e63652e",
"id": 3626,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "3436:21:6",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_a6eda769ef148ae7daceea0807fba3bdb2fa3b4cb61ab4c0c9299db72934c070",
"typeString": "literal_string \"Not enough balance.\""
},
"value": "Not enough balance."
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_a6eda769ef148ae7daceea0807fba3bdb2fa3b4cb61ab4c0c9299db72934c070",
"typeString": "literal_string \"Not enough balance.\""
}
],
"id": 3613,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
20642,
20643
],
"referencedDeclaration": 20643,
"src": "3366:7:6",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 3627,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "3366:92:6",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3628,
"nodeType": "ExpressionStatement",
"src": "3366:92:6"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3632,
"name": "_to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3601,
"src": "3491:3:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 3633,
"name": "_value",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3603,
"src": "3495:6:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"id": 3630,
"name": "super",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20723,
"src": "3476:5:6",
"typeDescriptions": {
"typeIdentifier": "t_super$_LockedToken_$3682",
"typeString": "contract super LockedToken"
}
},
"id": 3631,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "transfer",
"nodeType": "MemberAccess",
"referencedDeclaration": 20015,
"src": "3476:14:6",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$",
"typeString": "function (address,uint256) returns (bool)"
}
},
"id": 3634,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "3476:26:6",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 3629,
"name": "assert",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20628,
"src": "3469:6:6",
"typeDescriptions": {
"typeIdentifier": "t_function_assert_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 3635,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "3469:34:6",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3636,
"nodeType": "ExpressionStatement",
"src": "3469:34:6"
},
{
"expression": {
"argumentTypes": null,
"hexValue": "74727565",
"id": 3637,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "bool",
"lValueRequested": false,
"nodeType": "Literal",
"src": "3520:4:6",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"value": "true"
},
"functionReturnParameters": 3607,
"id": 3638,
"nodeType": "Return",
"src": "3513:11:6"
}
]
},
"documentation": "@dev Transfer token for a specified address.\n @param _to The address to transfer to.\n @param _value The amount to be transferred.",
"id": 3640,
"implemented": true,
"isConstructor": false,
"isDeclaredConst": false,
"modifiers": [],
"name": "transfer",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 3604,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3601,
"name": "_to",
"nodeType": "VariableDeclaration",
"scope": 3640,
"src": "3277:11:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3600,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "3277:7:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 3603,
"name": "_value",
"nodeType": "VariableDeclaration",
"scope": 3640,
"src": "3290:14:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3602,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "3290:7:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "3276:29:6"
},
"payable": false,
"returnParameters": {
"id": 3607,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3606,
"name": "",
"nodeType": "VariableDeclaration",
"scope": 3640,
"src": "3322:4:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 3605,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "3322:4:6",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "3321:6:6"
},
"scope": 3682,
"src": "3259:272:6",
"stateMutability": "nonpayable",
"superFunction": 20015,
"visibility": "public"
},
{
"body": {
"id": 3680,
"nodeType": "Block",
"src": "3904:198:6",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3652,
"name": "_from",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3642,
"src": "3921:5:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 3651,
"name": "unlock",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3507,
"src": "3914:6:6",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 3653,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "3914:13:6",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3654,
"nodeType": "ExpressionStatement",
"src": "3914:13:6"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 3665,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3660,
"name": "amountLocked",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3452,
"src": "3965:12:6",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
}
},
"id": 3662,
"indexExpression": {
"argumentTypes": null,
"id": 3661,
"name": "_from",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3642,
"src": "3978:5:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "3965:19:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3656,
"name": "balances",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 19945,
"src": "3945:8:6",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
}
},
"id": 3658,
"indexExpression": {
"argumentTypes": null,
"id": 3657,
"name": "_from",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3642,
"src": "3954:5:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "3945:15:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3659,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sub",
"nodeType": "MemberAccess",
"referencedDeclaration": 19821,
"src": "3945:19:6",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
"typeString": "function (uint256,uint256) pure returns (uint256)"
}
},
"id": 3663,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "3945:40:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": ">=",
"rightExpression": {
"argumentTypes": null,
"id": 3664,
"name": "_value",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3646,
"src": "3989:6:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "3945:50:6",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "4e6f7420656e6f7567682062616c616e63652e",
"id": 3666,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "3997:21:6",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_a6eda769ef148ae7daceea0807fba3bdb2fa3b4cb61ab4c0c9299db72934c070",
"typeString": "literal_string \"Not enough balance.\""
},
"value": "Not enough balance."
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_a6eda769ef148ae7daceea0807fba3bdb2fa3b4cb61ab4c0c9299db72934c070",
"typeString": "literal_string \"Not enough balance.\""
}
],
"id": 3655,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
20642,
20643
],
"referencedDeclaration": 20643,
"src": "3937:7:6",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 3667,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "3937:82:6",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3668,
"nodeType": "ExpressionStatement",
"src": "3937:82:6"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3672,
"name": "_from",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3642,
"src": "4056:5:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 3673,
"name": "_to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3644,
"src": "4062:3:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 3674,
"name": "_value",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3646,
"src": "4066:6:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"id": 3670,
"name": "super",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20723,
"src": "4037:5:6",
"typeDescriptions": {
"typeIdentifier": "t_super$_LockedToken_$3682",
"typeString": "contract super LockedToken"
}
},
"id": 3671,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "transferFrom",
"nodeType": "MemberAccess",
"referencedDeclaration": 20309,
"src": "4037:18:6",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$_t_bool_$",
"typeString": "function (address,address,uint256) returns (bool)"
}
},
"id": 3675,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "4037:36:6",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 3669,
"name": "assert",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20628,
"src": "4030:6:6",
"typeDescriptions": {
"typeIdentifier": "t_function_assert_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 3676,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "4030:44:6",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3677,
"nodeType": "ExpressionStatement",
"src": "4030:44:6"
},
{
"expression": {
"argumentTypes": null,
"hexValue": "74727565",
"id": 3678,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "bool",
"lValueRequested": false,
"nodeType": "Literal",
"src": "4091:4:6",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"value": "true"
},
"functionReturnParameters": 3650,
"id": 3679,
"nodeType": "Return",
"src": "4084:11:6"
}
]
},
"documentation": "@dev Transfer tokens from one address to another\n @param _from address The address which you want to send tokens from\n @param _to address The address which you want to transfer to\n @param _value uint256 the amount of tokens to be transferred",
"id": 3681,
"implemented": true,
"isConstructor": false,
"isDeclaredConst": false,
"modifiers": [],
"name": "transferFrom",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 3647,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3642,
"name": "_from",
"nodeType": "VariableDeclaration",
"scope": 3681,
"src": "3838:13:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3641,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "3838:7:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 3644,
"name": "_to",
"nodeType": "VariableDeclaration",
"scope": 3681,
"src": "3853:11:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3643,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "3853:7:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 3646,
"name": "_value",
"nodeType": "VariableDeclaration",
"scope": 3681,
"src": "3866:14:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3645,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "3866:7:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "3837:44:6"
},
"payable": false,
"returnParameters": {
"id": 3650,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3649,
"name": "",
"nodeType": "VariableDeclaration",
"scope": 3681,
"src": "3898:4:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 3648,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "3898:4:6",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "3897:6:6"
},
"scope": 3682,
"src": "3816:286:6",
"stateMutability": "nonpayable",
"superFunction": 20309,
"visibility": "public"
}
],
"scope": 3683,
"src": "525:3580:6"
}
],
"src": "159:3947:6"
},
"legacyAST": {
"absolutePath": "/private/tmp/kleros-interaction/contracts/standard/arbitration/ArbitrableTokens/LockedToken.sol",
"exportedSymbols": {
"LockedToken": [
3682
]
},
"id": 3683,
"nodeType": "SourceUnit",
"nodes": [
{
"id": 3436,
"literals": [
"solidity",
"^",
"0.4",
".15"
],
"nodeType": "PragmaDirective",
"src": "159:24:6"
},
{
"absolutePath": "openzeppelin-solidity/contracts/token/ERC20/MintableToken.sol",
"file": "openzeppelin-solidity/contracts/token/ERC20/MintableToken.sol",
"id": 3437,
"nodeType": "ImportDirective",
"scope": 3683,
"sourceUnit": 20210,
"src": "184:71:6",
"symbolAliases": [],
"unitAlias": ""
},
{
"baseContracts": [
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 3438,
"name": "MintableToken",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 20209,
"src": "549:13:6",
"typeDescriptions": {
"typeIdentifier": "t_contract$_MintableToken_$20209",
"typeString": "contract MintableToken"
}
},
"id": 3439,
"nodeType": "InheritanceSpecifier",
"src": "549:13:6"
}
],
"contractDependencies": [
19932,
20028,
20071,
20103,
20209,
20456
],
"contractKind": "contract",
"documentation": "@title Locked Token\n @dev A token when created coins are locked and unlock accross time.\n Note that we use steps for one month. In the future, when float are available, we could use law of exponential decay to avoid steps and have a smoothed unlocking.",
"fullyImplemented": true,
"id": 3682,
"linearizedBaseContracts": [
3682,
20209,
19932,
20456,
20028,
20071,
20103
],
"name": "LockedToken",
"nodeType": "ContractDefinition",
"nodes": [
{
"constant": false,
"id": 3441,
"name": "lockMultiplierPerMillionPerMonth",
"nodeType": "VariableDeclaration",
"scope": 3682,
"src": "569:44:6",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3440,
"name": "uint",
"nodeType": "ElementaryTypeName",
"src": "569:4:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "public"
},
{
"constant": true,
"id": 3444,
"name": "LOCK_DIVISOR",
"nodeType": "VariableDeclaration",
"scope": 3682,
"src": "681:32:6",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3442,
"name": "uint",
"nodeType": "ElementaryTypeName",
"src": "681:4:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": {
"argumentTypes": null,
"hexValue": "314536",
"id": 3443,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "710:3:6",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_1000000_by_1",
"typeString": "int_const 1000000"
},
"value": "1E6"
},
"visibility": "internal"
},
{
"constant": false,
"id": 3448,
"name": "lastUnlock",
"nodeType": "VariableDeclaration",
"scope": 3682,
"src": "719:43:6",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
},
"typeName": {
"id": 3447,
"keyType": {
"id": 3445,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "728:7:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "Mapping",
"src": "719:25:6",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
},
"valueType": {
"id": 3446,
"name": "uint",
"nodeType": "ElementaryTypeName",
"src": "739:4:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
},
"value": null,
"visibility": "public"
},
{
"constant": false,
"id": 3452,
"name": "amountLocked",
"nodeType": "VariableDeclaration",
"scope": 3682,
"src": "803:45:6",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
},
"typeName": {
"id": 3451,
"keyType": {
"id": 3449,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "812:7:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "Mapping",
"src": "803:25:6",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
},
"valueType": {
"id": 3450,
"name": "uint",
"nodeType": "ElementaryTypeName",
"src": "823:4:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
},
"value": null,
"visibility": "public"
},
{
"body": {
"id": 3461,
"nodeType": "Block",
"src": "1258:85:6",
"statements": [
{
"expression": {
"argumentTypes": null,
"id": 3459,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"id": 3457,
"name": "lockMultiplierPerMillionPerMonth",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3441,
"src": "1268:32:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"id": 3458,
"name": "_lockMultiplierPerMillionPerMonth",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3454,
"src": "1303:33:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "1268:68:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3460,
"nodeType": "ExpressionStatement",
"src": "1268:68:6"
}
]
},
"documentation": "@dev Constructor.\n @param _lockMultiplierPerMillionPerMonth The amount we must multiply the locked portion each month.\n It is (1-unlockRatioPerYear)^(1/12) * 1E6. Note that we should compute that offchain to avoid integer rounding.\n So for 10% unlock per year, it is 991258.",
"id": 3462,
"implemented": true,
"isConstructor": true,
"isDeclaredConst": false,
"modifiers": [],
"name": "",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 3455,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3454,
"name": "_lockMultiplierPerMillionPerMonth",
"nodeType": "VariableDeclaration",
"scope": 3462,
"src": "1211:38:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3453,
"name": "uint",
"nodeType": "ElementaryTypeName",
"src": "1211:4:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "1210:40:6"
},
"payable": false,
"returnParameters": {
"id": 3456,
"nodeType": "ParameterList",
"parameters": [],
"src": "1258:0:6"
},
"scope": 3682,
"src": "1199:144:6",
"stateMutability": "nonpayable",
"superFunction": null,
"visibility": "public"
},
{
"body": {
"id": 3492,
"nodeType": "Block",
"src": "1644:130:6",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3472,
"name": "_to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3464,
"src": "1661:3:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 3471,
"name": "unlock",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3507,
"src": "1654:6:6",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 3473,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "1654:11:6",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3474,
"nodeType": "ExpressionStatement",
"src": "1654:11:6"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3478,
"name": "_to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3464,
"src": "1693:3:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 3479,
"name": "_amount",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3466,
"src": "1697:7:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"id": 3476,
"name": "super",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20723,
"src": "1682:5:6",
"typeDescriptions": {
"typeIdentifier": "t_super$_LockedToken_$3682",
"typeString": "contract super LockedToken"
}
},
"id": 3477,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "mint",
"nodeType": "MemberAccess",
"referencedDeclaration": 20189,
"src": "1682:10:6",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$",
"typeString": "function (address,uint256) returns (bool)"
}
},
"id": 3480,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "1682:23:6",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 3475,
"name": "assert",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20628,
"src": "1675:6:6",
"typeDescriptions": {
"typeIdentifier": "t_function_assert_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 3481,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "1675:31:6",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3482,
"nodeType": "ExpressionStatement",
"src": "1675:31:6"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3487,
"name": "_amount",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3466,
"src": "1738:7:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3483,
"name": "amountLocked",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3452,
"src": "1716:12:6",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
}
},
"id": 3485,
"indexExpression": {
"argumentTypes": null,
"id": 3484,
"name": "_to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3464,
"src": "1729:3:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "1716:17:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3486,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "add",
"nodeType": "MemberAccess",
"referencedDeclaration": 19845,
"src": "1716:21:6",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
"typeString": "function (uint256,uint256) pure returns (uint256)"
}
},
"id": 3488,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "1716:30:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3489,
"nodeType": "ExpressionStatement",
"src": "1716:30:6"
},
{
"expression": {
"argumentTypes": null,
"hexValue": "74727565",
"id": 3490,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "bool",
"lValueRequested": false,
"nodeType": "Literal",
"src": "1763:4:6",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"value": "true"
},
"functionReturnParameters": 3470,
"id": 3491,
"nodeType": "Return",
"src": "1756:11:6"
}
]
},
"documentation": "@dev Mint tokens.\n @param _to The address that will receive the minted tokens.\n @param _amount The amount of tokens to mint.\n @return A boolean that indicates if the operation was successful.",
"id": 3493,
"implemented": true,
"isConstructor": false,
"isDeclaredConst": false,
"modifiers": [],
"name": "mint",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 3467,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3464,
"name": "_to",
"nodeType": "VariableDeclaration",
"scope": 3493,
"src": "1592:11:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3463,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "1592:7:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 3466,
"name": "_amount",
"nodeType": "VariableDeclaration",
"scope": 3493,
"src": "1605:15:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3465,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "1605:7:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "1591:30:6"
},
"payable": false,
"returnParameters": {
"id": 3470,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3469,
"name": "",
"nodeType": "VariableDeclaration",
"scope": 3493,
"src": "1638:4:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 3468,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "1638:4:6",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "1637:6:6"
},
"scope": 3682,
"src": "1578:196:6",
"stateMutability": "nonpayable",
"superFunction": 20189,
"visibility": "public"
},
{
"body": {
"id": 3506,
"nodeType": "Block",
"src": "2199:44:6",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3499,
"name": "_to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3495,
"src": "2223:3:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3502,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "UnaryOperation",
"operator": "-",
"prefix": true,
"src": "2232:2:6",
"subExpression": {
"argumentTypes": null,
"hexValue": "31",
"id": 3501,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "2233:1:6",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_1_by_1",
"typeString": "int_const 1"
},
"value": "1"
},
"typeDescriptions": {
"typeIdentifier": "t_rational_-1_by_1",
"typeString": "int_const -1"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_rational_-1_by_1",
"typeString": "int_const -1"
}
],
"id": 3500,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "2227:4:6",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_uint256_$",
"typeString": "type(uint256)"
},
"typeName": "uint"
},
"id": 3503,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "2227:8:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"id": 3498,
"name": "partialUnlock",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3599,
"src": "2209:13:6",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$__$",
"typeString": "function (address,uint256)"
}
},
"id": 3504,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "2209:27:6",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3505,
"nodeType": "ExpressionStatement",
"src": "2209:27:6"
}
]
},
"documentation": "@dev Unlock the tokens which can.\n Note that this function is O(log(t)) where t is the last time of unlock.\n You can call partiallUnlock with a maxUnlock to avoid gas issues.\n But note that it is likely to never be necessary as the cost of this function, if not high even for multiple years.\n @param _to The address to unlock tokens from.",
"id": 3507,
"implemented": true,
"isConstructor": false,
"isDeclaredConst": false,
"modifiers": [],
"name": "unlock",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 3496,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3495,
"name": "_to",
"nodeType": "VariableDeclaration",
"scope": 3507,
"src": "2179:11:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3494,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "2179:7:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "2178:13:6"
},
"payable": false,
"returnParameters": {
"id": 3497,
"nodeType": "ParameterList",
"parameters": [],
"src": "2199:0:6"
},
"scope": 3682,
"src": "2163:80:6",
"stateMutability": "nonpayable",
"superFunction": null,
"visibility": "public"
},
{
"body": {
"id": 3598,
"nodeType": "Block",
"src": "2493:600:6",
"statements": [
{
"condition": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"id": 3527,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 3521,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "34",
"id": 3518,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "2527:7:6",
"subdenomination": "weeks",
"typeDescriptions": {
"typeIdentifier": "t_rational_2419200_by_1",
"typeString": "int_const 2419200"
},
"value": "4"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_rational_2419200_by_1",
"typeString": "int_const 2419200"
}
],
"expression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3514,
"name": "lastUnlock",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3448,
"src": "2507:10:6",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
}
},
"id": 3516,
"indexExpression": {
"argumentTypes": null,
"id": 3515,
"name": "_to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3509,
"src": "2518:3:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "2507:15:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3517,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "add",
"nodeType": "MemberAccess",
"referencedDeclaration": 19845,
"src": "2507:19:6",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
"typeString": "function (uint256,uint256) pure returns (uint256)"
}
},
"id": 3519,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "2507:28:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "<=",
"rightExpression": {
"argumentTypes": null,
"id": 3520,
"name": "now",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20641,
"src": "2539:3:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "2507:35:6",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"nodeType": "BinaryOperation",
"operator": "&&",
"rightExpression": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 3526,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3522,
"name": "amountLocked",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3452,
"src": "2546:12:6",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
}
},
"id": 3524,
"indexExpression": {
"argumentTypes": null,
"id": 3523,
"name": "_to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3509,
"src": "2559:3:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "2546:17:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "!=",
"rightExpression": {
"argumentTypes": null,
"hexValue": "30",
"id": 3525,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "2565:1:6",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
},
"src": "2546:20:6",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"src": "2507:59:6",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"falseBody": null,
"id": 3597,
"nodeType": "IfStatement",
"src": "2503:584:6",
"trueBody": {
"id": 3596,
"nodeType": "Block",
"src": "2568:519:6",
"statements": [
{
"assignments": [
3529
],
"declarations": [
{
"constant": false,
"id": 3529,
"name": "amountOfMonths",
"nodeType": "VariableDeclaration",
"scope": 3599,
"src": "2582:19:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3528,
"name": "uint",
"nodeType": "ElementaryTypeName",
"src": "2582:4:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 3539,
"initialValue": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 3538,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3532,
"name": "lastUnlock",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3448,
"src": "2612:10:6",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
}
},
"id": 3534,
"indexExpression": {
"argumentTypes": null,
"id": 3533,
"name": "_to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3509,
"src": "2623:3:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "2612:15:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"id": 3530,
"name": "now",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20641,
"src": "2604:3:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3531,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sub",
"nodeType": "MemberAccess",
"referencedDeclaration": 19821,
"src": "2604:7:6",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
"typeString": "function (uint256,uint256) pure returns (uint256)"
}
},
"id": 3535,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "2604:24:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "/",
"rightExpression": {
"argumentTypes": null,
"components": [
{
"argumentTypes": null,
"hexValue": "34",
"id": 3536,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "2632:7:6",
"subdenomination": "weeks",
"typeDescriptions": {
"typeIdentifier": "t_rational_2419200_by_1",
"typeString": "int_const 2419200"
},
"value": "4"
}
],
"id": 3537,
"isConstant": false,
"isInlineArray": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "TupleExpression",
"src": "2631:9:6",
"typeDescriptions": {
"typeIdentifier": "t_rational_2419200_by_1",
"typeString": "int_const 2419200"
}
},
"src": "2604:36:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "2582:58:6"
},
{
"expression": {
"argumentTypes": null,
"id": 3547,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"id": 3540,
"name": "amountOfMonths",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3529,
"src": "2654:14:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"condition": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 3543,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 3541,
"name": "amountOfMonths",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3529,
"src": "2671:14:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "<",
"rightExpression": {
"argumentTypes": null,
"id": 3542,
"name": "_maxUnlock",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3511,
"src": "2688:10:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "2671:27:6",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"falseExpression": {
"argumentTypes": null,
"id": 3545,
"name": "_maxUnlock",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3511,
"src": "2718:10:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3546,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"nodeType": "Conditional",
"src": "2671:57:6",
"trueExpression": {
"argumentTypes": null,
"id": 3544,
"name": "amountOfMonths",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3529,
"src": "2701:14:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "2654:74:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3548,
"nodeType": "ExpressionStatement",
"src": "2654:74:6"
},
{
"expression": {
"argumentTypes": null,
"id": 3561,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3549,
"name": "lastUnlock",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3448,
"src": "2742:10:6",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
}
},
"id": 3551,
"indexExpression": {
"argumentTypes": null,
"id": 3550,
"name": "_to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3509,
"src": "2753:3:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "2742:15:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "34",
"id": 3558,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "2799:7:6",
"subdenomination": "weeks",
"typeDescriptions": {
"typeIdentifier": "t_rational_2419200_by_1",
"typeString": "int_const 2419200"
},
"value": "4"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_rational_2419200_by_1",
"typeString": "int_const 2419200"
}
],
"expression": {
"argumentTypes": null,
"id": 3556,
"name": "amountOfMonths",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3529,
"src": "2780:14:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3557,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "mul",
"nodeType": "MemberAccess",
"referencedDeclaration": 19787,
"src": "2780:18:6",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
"typeString": "function (uint256,uint256) pure returns (uint256)"
}
},
"id": 3559,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "2780:27:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3552,
"name": "lastUnlock",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3448,
"src": "2760:10:6",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
}
},
"id": 3554,
"indexExpression": {
"argumentTypes": null,
"id": 3553,
"name": "_to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3509,
"src": "2771:3:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "2760:15:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3555,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "add",
"nodeType": "MemberAccess",
"referencedDeclaration": 19845,
"src": "2760:19:6",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
"typeString": "function (uint256,uint256) pure returns (uint256)"
}
},
"id": 3560,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "2760:48:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "2742:66:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3562,
"nodeType": "ExpressionStatement",
"src": "2742:66:6"
},
{
"assignments": [
3564
],
"declarations": [
{
"constant": false,
"id": 3564,
"name": "newLocked",
"nodeType": "VariableDeclaration",
"scope": 3599,
"src": "2850:14:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3563,
"name": "uint",
"nodeType": "ElementaryTypeName",
"src": "2850:4:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 3568,
"initialValue": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3565,
"name": "amountLocked",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3452,
"src": "2867:12:6",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
}
},
"id": 3567,
"indexExpression": {
"argumentTypes": null,
"id": 3566,
"name": "_to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3509,
"src": "2880:3:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "2867:17:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "2850:34:6"
},
{
"body": {
"expression": {
"argumentTypes": null,
"id": 3587,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"id": 3579,
"name": "newLocked",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3564,
"src": "2956:9:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3585,
"name": "LOCK_DIVISOR",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3444,
"src": "3020:12:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3582,
"name": "lockMultiplierPerMillionPerMonth",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3441,
"src": "2982:32:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"id": 3580,
"name": "newLocked",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3564,
"src": "2968:9:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3581,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "mul",
"nodeType": "MemberAccess",
"referencedDeclaration": 19787,
"src": "2968:13:6",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
"typeString": "function (uint256,uint256) pure returns (uint256)"
}
},
"id": 3583,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "2968:47:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3584,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "div",
"nodeType": "MemberAccess",
"referencedDeclaration": 19801,
"src": "2968:51:6",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
"typeString": "function (uint256,uint256) pure returns (uint256)"
}
},
"id": 3586,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "2968:65:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "2956:77:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3588,
"nodeType": "ExpressionStatement",
"src": "2956:77:6"
},
"condition": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 3575,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 3573,
"name": "i",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3570,
"src": "2915:1:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "<",
"rightExpression": {
"argumentTypes": null,
"id": 3574,
"name": "amountOfMonths",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3529,
"src": "2919:14:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "2915:18:6",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"id": 3589,
"initializationExpression": {
"assignments": [
3570
],
"declarations": [
{
"constant": false,
"id": 3570,
"name": "i",
"nodeType": "VariableDeclaration",
"scope": 3599,
"src": "2903:6:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3569,
"name": "uint",
"nodeType": "ElementaryTypeName",
"src": "2903:4:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 3572,
"initialValue": {
"argumentTypes": null,
"hexValue": "30",
"id": 3571,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "2912:1:6",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
},
"nodeType": "VariableDeclarationStatement",
"src": "2903:10:6"
},
"loopExpression": {
"expression": {
"argumentTypes": null,
"id": 3577,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"nodeType": "UnaryOperation",
"operator": "++",
"prefix": true,
"src": "2935:3:6",
"subExpression": {
"argumentTypes": null,
"id": 3576,
"name": "i",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3570,
"src": "2937:1:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3578,
"nodeType": "ExpressionStatement",
"src": "2935:3:6"
},
"nodeType": "ForStatement",
"src": "2898:135:6"
},
{
"expression": {
"argumentTypes": null,
"id": 3594,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3590,
"name": "amountLocked",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3452,
"src": "3047:12:6",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
}
},
"id": 3592,
"indexExpression": {
"argumentTypes": null,
"id": 3591,
"name": "_to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3509,
"src": "3060:3:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "3047:17:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"id": 3593,
"name": "newLocked",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3564,
"src": "3067:9:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "3047:29:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3595,
"nodeType": "ExpressionStatement",
"src": "3047:29:6"
}
]
}
}
]
},
"documentation": "@dev Unlock the tokens which can.\n This function is O(_maxUnlock). You may need to call it multiple times.\n @param _to The address to unlock tokens from.",
"id": 3599,
"implemented": true,
"isConstructor": false,
"isDeclaredConst": false,
"modifiers": [],
"name": "partialUnlock",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 3512,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3509,
"name": "_to",
"nodeType": "VariableDeclaration",
"scope": 3599,
"src": "2456:11:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3508,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "2456:7:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 3511,
"name": "_maxUnlock",
"nodeType": "VariableDeclaration",
"scope": 3599,
"src": "2469:15:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3510,
"name": "uint",
"nodeType": "ElementaryTypeName",
"src": "2469:4:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "2455:30:6"
},
"payable": false,
"returnParameters": {
"id": 3513,
"nodeType": "ParameterList",
"parameters": [],
"src": "2493:0:6"
},
"scope": 3682,
"src": "2433:660:6",
"stateMutability": "nonpayable",
"superFunction": null,
"visibility": "public"
},
{
"body": {
"id": 3639,
"nodeType": "Block",
"src": "3328:203:6",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 3609,
"name": "msg",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20639,
"src": "3345:3:6",
"typeDescriptions": {
"typeIdentifier": "t_magic_message",
"typeString": "msg"
}
},
"id": 3610,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sender",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "3345:10:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 3608,
"name": "unlock",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3507,
"src": "3338:6:6",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 3611,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "3338:18:6",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3612,
"nodeType": "ExpressionStatement",
"src": "3338:18:6"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 3625,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3619,
"name": "amountLocked",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3452,
"src": "3399:12:6",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
}
},
"id": 3622,
"indexExpression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 3620,
"name": "msg",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20639,
"src": "3412:3:6",
"typeDescriptions": {
"typeIdentifier": "t_magic_message",
"typeString": "msg"
}
},
"id": 3621,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sender",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "3412:10:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "3399:24:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3614,
"name": "balances",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 19945,
"src": "3374:8:6",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
}
},
"id": 3617,
"indexExpression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 3615,
"name": "msg",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20639,
"src": "3383:3:6",
"typeDescriptions": {
"typeIdentifier": "t_magic_message",
"typeString": "msg"
}
},
"id": 3616,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sender",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "3383:10:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "3374:20:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3618,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sub",
"nodeType": "MemberAccess",
"referencedDeclaration": 19821,
"src": "3374:24:6",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
"typeString": "function (uint256,uint256) pure returns (uint256)"
}
},
"id": 3623,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "3374:50:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": ">=",
"rightExpression": {
"argumentTypes": null,
"id": 3624,
"name": "_value",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3603,
"src": "3428:6:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "3374:60:6",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "4e6f7420656e6f7567682062616c616e63652e",
"id": 3626,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "3436:21:6",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_a6eda769ef148ae7daceea0807fba3bdb2fa3b4cb61ab4c0c9299db72934c070",
"typeString": "literal_string \"Not enough balance.\""
},
"value": "Not enough balance."
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_a6eda769ef148ae7daceea0807fba3bdb2fa3b4cb61ab4c0c9299db72934c070",
"typeString": "literal_string \"Not enough balance.\""
}
],
"id": 3613,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
20642,
20643
],
"referencedDeclaration": 20643,
"src": "3366:7:6",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 3627,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "3366:92:6",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3628,
"nodeType": "ExpressionStatement",
"src": "3366:92:6"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3632,
"name": "_to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3601,
"src": "3491:3:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 3633,
"name": "_value",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3603,
"src": "3495:6:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"id": 3630,
"name": "super",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20723,
"src": "3476:5:6",
"typeDescriptions": {
"typeIdentifier": "t_super$_LockedToken_$3682",
"typeString": "contract super LockedToken"
}
},
"id": 3631,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "transfer",
"nodeType": "MemberAccess",
"referencedDeclaration": 20015,
"src": "3476:14:6",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$",
"typeString": "function (address,uint256) returns (bool)"
}
},
"id": 3634,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "3476:26:6",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 3629,
"name": "assert",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20628,
"src": "3469:6:6",
"typeDescriptions": {
"typeIdentifier": "t_function_assert_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 3635,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "3469:34:6",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3636,
"nodeType": "ExpressionStatement",
"src": "3469:34:6"
},
{
"expression": {
"argumentTypes": null,
"hexValue": "74727565",
"id": 3637,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "bool",
"lValueRequested": false,
"nodeType": "Literal",
"src": "3520:4:6",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"value": "true"
},
"functionReturnParameters": 3607,
"id": 3638,
"nodeType": "Return",
"src": "3513:11:6"
}
]
},
"documentation": "@dev Transfer token for a specified address.\n @param _to The address to transfer to.\n @param _value The amount to be transferred.",
"id": 3640,
"implemented": true,
"isConstructor": false,
"isDeclaredConst": false,
"modifiers": [],
"name": "transfer",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 3604,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3601,
"name": "_to",
"nodeType": "VariableDeclaration",
"scope": 3640,
"src": "3277:11:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3600,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "3277:7:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 3603,
"name": "_value",
"nodeType": "VariableDeclaration",
"scope": 3640,
"src": "3290:14:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3602,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "3290:7:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "3276:29:6"
},
"payable": false,
"returnParameters": {
"id": 3607,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3606,
"name": "",
"nodeType": "VariableDeclaration",
"scope": 3640,
"src": "3322:4:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 3605,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "3322:4:6",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "3321:6:6"
},
"scope": 3682,
"src": "3259:272:6",
"stateMutability": "nonpayable",
"superFunction": 20015,
"visibility": "public"
},
{
"body": {
"id": 3680,
"nodeType": "Block",
"src": "3904:198:6",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3652,
"name": "_from",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3642,
"src": "3921:5:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 3651,
"name": "unlock",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3507,
"src": "3914:6:6",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 3653,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "3914:13:6",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3654,
"nodeType": "ExpressionStatement",
"src": "3914:13:6"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 3665,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3660,
"name": "amountLocked",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3452,
"src": "3965:12:6",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
}
},
"id": 3662,
"indexExpression": {
"argumentTypes": null,
"id": 3661,
"name": "_from",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3642,
"src": "3978:5:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "3965:19:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3656,
"name": "balances",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 19945,
"src": "3945:8:6",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
}
},
"id": 3658,
"indexExpression": {
"argumentTypes": null,
"id": 3657,
"name": "_from",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3642,
"src": "3954:5:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "3945:15:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3659,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sub",
"nodeType": "MemberAccess",
"referencedDeclaration": 19821,
"src": "3945:19:6",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
"typeString": "function (uint256,uint256) pure returns (uint256)"
}
},
"id": 3663,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "3945:40:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": ">=",
"rightExpression": {
"argumentTypes": null,
"id": 3664,
"name": "_value",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3646,
"src": "3989:6:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "3945:50:6",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "4e6f7420656e6f7567682062616c616e63652e",
"id": 3666,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "3997:21:6",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_a6eda769ef148ae7daceea0807fba3bdb2fa3b4cb61ab4c0c9299db72934c070",
"typeString": "literal_string \"Not enough balance.\""
},
"value": "Not enough balance."
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_a6eda769ef148ae7daceea0807fba3bdb2fa3b4cb61ab4c0c9299db72934c070",
"typeString": "literal_string \"Not enough balance.\""
}
],
"id": 3655,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
20642,
20643
],
"referencedDeclaration": 20643,
"src": "3937:7:6",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 3667,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "3937:82:6",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3668,
"nodeType": "ExpressionStatement",
"src": "3937:82:6"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3672,
"name": "_from",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3642,
"src": "4056:5:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 3673,
"name": "_to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3644,
"src": "4062:3:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 3674,
"name": "_value",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3646,
"src": "4066:6:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"id": 3670,
"name": "super",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20723,
"src": "4037:5:6",
"typeDescriptions": {
"typeIdentifier": "t_super$_LockedToken_$3682",
"typeString": "contract super LockedToken"
}
},
"id": 3671,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "transferFrom",
"nodeType": "MemberAccess",
"referencedDeclaration": 20309,
"src": "4037:18:6",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$_t_bool_$",
"typeString": "function (address,address,uint256) returns (bool)"
}
},
"id": 3675,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "4037:36:6",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 3669,
"name": "assert",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 20628,
"src": "4030:6:6",
"typeDescriptions": {
"typeIdentifier": "t_function_assert_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 3676,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "4030:44:6",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3677,
"nodeType": "ExpressionStatement",
"src": "4030:44:6"
},
{
"expression": {
"argumentTypes": null,
"hexValue": "74727565",
"id": 3678,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "bool",
"lValueRequested": false,
"nodeType": "Literal",
"src": "4091:4:6",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"value": "true"
},
"functionReturnParameters": 3650,
"id": 3679,
"nodeType": "Return",
"src": "4084:11:6"
}
]
},
"documentation": "@dev Transfer tokens from one address to another\n @param _from address The address which you want to send tokens from\n @param _to address The address which you want to transfer to\n @param _value uint256 the amount of tokens to be transferred",
"id": 3681,
"implemented": true,
"isConstructor": false,
"isDeclaredConst": false,
"modifiers": [],
"name": "transferFrom",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 3647,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3642,
"name": "_from",
"nodeType": "VariableDeclaration",
"scope": 3681,
"src": "3838:13:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3641,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "3838:7:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 3644,
"name": "_to",
"nodeType": "VariableDeclaration",
"scope": 3681,
"src": "3853:11:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3643,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "3853:7:6",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 3646,
"name": "_value",
"nodeType": "VariableDeclaration",
"scope": 3681,
"src": "3866:14:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3645,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "3866:7:6",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "3837:44:6"
},
"payable": false,
"returnParameters": {
"id": 3650,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3649,
"name": "",
"nodeType": "VariableDeclaration",
"scope": 3681,
"src": "3898:4:6",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 3648,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "3898:4:6",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "3897:6:6"
},
"scope": 3682,
"src": "3816:286:6",
"stateMutability": "nonpayable",
"superFunction": 20309,
"visibility": "public"
}
],
"scope": 3683,
"src": "525:3580:6"
}
],
"src": "159:3947:6"
},
"compiler": {
"name": "solc",
"version": "0.4.24+commit.e67f0147.Emscripten.clang"
},
"networks": {},
"schemaVersion": "2.0.1",
"updatedAt": "2018-11-02T14:04:10.965Z"
}