2021-01-18 13:25:25 +00:00
|
|
|
contract C {
|
|
|
|
struct S {
|
|
|
|
uint a;
|
|
|
|
}
|
|
|
|
S s;
|
|
|
|
mapping (uint => S) m;
|
|
|
|
|
|
|
|
function f() external returns (bool) {
|
|
|
|
s.a = 12;
|
|
|
|
m[1] = s;
|
|
|
|
return m[1].a == 12;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
// ====
|
|
|
|
// compileViaYul: also
|
|
|
|
// ----
|
2021-03-12 23:02:36 +00:00
|
|
|
// f() -> true
|