Here is the code snipped which is used when I'am working with compiler version 0.4.6 :
function approveAndCall(address _spender, uint256 _value, bytes memory _extraData) public returns (bool success) {
allowed[msg.sender][_spender] = _value;
emit Approval(msg.sender, _spender, _value);
if(!_spender.call(bytes4(bytes32(sha3("receiveApproval(address,uint256,address,bytes)"))), msg.sender, _value, this, _extraData)) {
throw;
}
return true;
}
Now I'm compiling this code with version 0.5.1, what should I do? I've already referred Read the Docs content : v0.5.0 Breaking Changes, but really I didn't understand it.