solidity/test/libsolidity/semanticTests/structs/struct_named_constructor.sol

15 lines
180 B
Solidity
Raw Normal View History

contract C {
struct S {
uint256 a;
bool x;
}
S public s;
constructor() public {
s = S({a: 1, x: true});
}
}
// ----
// s() -> 1, true