Commit aad25205 by Francisco Giordano

add comment making explicit that SafeMath.sub can throw

parent dcdc453a
......@@ -22,6 +22,7 @@ contract BasicToken is ERC20Basic {
function transfer(address _to, uint256 _value) returns (bool) {
require(_to != address(0));
// SafeMath.sub will throw if there is not enough balance.
balances[msg.sender] = balances[msg.sender].sub(_value);
balances[_to] = balances[_to].add(_value);
Transfer(msg.sender, _to, _value);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment