in my last smart contract(solidity ^0.4.11) its work correctly, but now (solidity ^0.4.18) I get warnings.
. This declaration shadows an existing declaration.
. Function state mutability can be restricted to view
function freezeAccount(address target, bool freeze) public onlyOwner {
frozenAccount[target] = freeze;
FrozenFunds(target, freeze);
}
function frozen(address _target) public returns (bool frozen) {
return frozenAccount[_target];
}
Cand understand, whats the problem? I have functions like this and no errors.
frozen
as a variable name and as a function name. The compiler now is more strict and show a warning that it can be problematic to have both with the same name. – Ismael Feb 2 '18 at 16:53