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

22 lines
296 B
Solidity

contract E {}
library L {
function foo(E e) internal pure returns (uint) {
return 42;
}
}
contract C {
using L for E;
function test() public returns (uint) {
E e = new E();
return e.foo();
}
}
// ====
// compileViaYul: also
// ----
// test() -> 42