solang-parser 0.2.1

Solang Solidity Parser
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
pragma abicoder               v2;

contract C {
    struct S { function () external returns (uint) f; uint b; }
    function f(S memory s) public returns (uint, uint) {
        return (s.f(), s.b);
    }
    function test() public returns (uint, uint) {
        return this.f(S(this.g, 3));
    }
    function g() public returns (uint) { return 7; }
}
// ====
// compileViaYul: also
// ----
// test() -> 7, 3