mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
9 lines
375 B
Solidity
9 lines
375 B
Solidity
|
contract test {
|
||
|
function f(uint8 a) public returns (uint) { return a; }
|
||
|
function f(uint a) public returns (uint) { return 2 * a; }
|
||
|
// literal 1 can be both converted to uint and uint8, so the call is ambiguous.
|
||
|
function g() public returns (uint) { return f(1); }
|
||
|
}
|
||
|
// ----
|
||
|
// TypeError: (271-272): No unique declaration found after argument-dependent lookup.
|