solidity/test/libsolidity/semanticTests/constructor_with_params.sol

16 lines
243 B
Solidity
Raw Normal View History

contract C {
uint public i;
uint public k;
2020-06-23 12:14:24 +00:00
constructor(uint newI, uint newK) {
i = newI;
k = newK;
}
}
// ----
// constructor(): 2, 0 ->
// gas irOptimized: 102902
// gas legacy: 115678
// i() -> 2
// k() -> 0