Fix error msg hint for non-payable contracts

This commit is contained in:
Mathias Baumann
2019-02-14 11:39:19 +01:00
parent f003696d7e
commit 10a9960eb3
3 changed files with 33 additions and 21 deletions
@@ -0,0 +1,8 @@
contract C {
function f() public {
address(this).send(10);
}
}
// ----
// TypeError: (47-65): "send" and "transfer" are only available for objects of type "address payable", not "address".
@@ -0,0 +1,8 @@
contract C {
function f() public {
address(this).transfer(10);
}
}
// ----
// TypeError: (47-69): "send" and "transfer" are only available for objects of type "address payable", not "address".