mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
18 lines
537 B
Solidity
18 lines
537 B
Solidity
|
contract C {
|
||
|
function g() public returns (uint a, function() external h, uint b) {
|
||
|
a = 1;
|
||
|
h = this.fun;
|
||
|
b = 9;
|
||
|
}
|
||
|
function f() public returns (uint, function() external, uint) {
|
||
|
// Note that the function type uses two stack slots.
|
||
|
try this.g() returns (uint a, function() external h, uint b) {
|
||
|
return (a, h, b);
|
||
|
} catch {
|
||
|
}
|
||
|
}
|
||
|
function fun() public pure {}
|
||
|
}
|
||
|
// ----
|
||
|
// f() -> 0x1, 0xfdd67305928fcac8d213d1e47bfa6165cd0b87b946644cd0000000000000000, 9
|