solidity/test/libsolidity/syntaxTests/immutable/reading_after_initialization_function.sol
2023-07-14 15:29:32 +02:00

16 lines
157 B
Solidity

contract C {
uint immutable x;
constructor()
{
readX();
x = 3;
readX();
}
function readX() public view returns(uint) {
return x;
}
}
// ----