solidity/test/libsolidity/semanticTests/structs/memory_struct_named_constructor.sol
2020-07-02 16:37:20 +02:00

19 lines
254 B
Solidity

pragma experimental ABIEncoderV2;
contract C {
struct S {
uint256 a;
bool x;
}
function s() public returns(S memory)
{
return S({x: true, a: 8});
}
}
// ====
// compileViaYul: also
// ----
// s() -> 8, true