solidity/test/libsolidity/semanticTests/libraries/internal_library_function_pointer.sol

18 lines
285 B
Solidity
Raw Normal View History

library L {
function f() internal returns (uint) {
return 66;
}
}
contract C {
function g() public returns (uint) {
function() internal returns(uint) ptr;
ptr = L.f;
return ptr();
}
}
// ====
// compileViaYul: also
// ----
// g() -> 66