solidity/test/libsolidity/syntaxTests/inlineAssembly/constant_access_non_initialized.sol

12 lines
240 B
Solidity

contract C {
uint constant x;
function f() public pure {
assembly {
let c1 := x
}
}
}
// ----
// TypeError: (17-32): Uninitialized "constant" variable.
// TypeError: (106-107): Constant has no value.