solidity/test/libsolidity/semanticTests/various/balance.sol

15 lines
267 B
Solidity
Raw Normal View History

contract test {
2020-06-23 12:14:24 +00:00
constructor() payable {}
function getBalance() public returns (uint256 balance) {
return address(this).balance;
}
}
// ====
// compileToEwasm: also
// compileViaYul: also
// ----
// constructor(), 23 wei ->
// getBalance() -> 23