solidity/test/libsolidity/syntaxTests/inheritance/override/change_return_types_in_interface.sol
2018-11-26 16:51:45 +01:00

11 lines
307 B
Solidity

interface I {
function f() external pure returns (uint);
}
contract B is I {
// The compiler used to have a bug where changing
// the return type was fine in this situation.
function f() public pure returns (uint, uint) {}
}
// ----
// TypeError: (182-230): Overriding function return types differ.