solidity/test/libsolidity/syntaxTests/returnExpressions/tuple_return_mismatching_number.sol
2018-08-07 20:49:52 +02:00

20 lines
527 B
Solidity

contract C
{
function f() public pure returns (uint, uint)
{
return 1;
}
function g() public pure returns (uint, uint)
{
return (1, 2, 3);
}
function h() public pure returns (uint, uint)
{
return;
}
}
// ----
// TypeError: (77-85): Different number of arguments in return statement than in returns declaration.
// TypeError: (157-173): Different number of arguments in return statement than in returns declaration.
// TypeError: (245-252): Return arguments required.