Create test overflow solidity file

pull/112/head
Joran Honig 7 years ago
parent aa5db8ba3b
commit b087826bad
  1. 20
      tests/testdata/inputs/overflow.sol

@ -0,0 +1,20 @@
contract Over {
mapping(address => uint) balances;
uint public totalSupply;
function Token(uint _initialSupply) {
balances[msg.sender] = totalSupply = _initialSupply;
}
function sendeth(address _to, uint _value) public returns (bool) {
require(balances[msg.sender] - _value >= 0);
balances[msg.sender] -= _value;
balances[_to] += _value;
return true;
}
function balanceOf(address _owner) public constant returns (uint balance) {
return balances[_owner];
}
}
Loading…
Cancel
Save