solidity/test/libsolidity/syntaxTests/inheritance/override/add_view.sol
2019-11-14 11:49:39 +01:00

6 lines
275 B
Solidity

contract B { function f() virtual public {} }
contract C is B { function f() public view {} }
// ----
// TypeError: (64-91): Overriding function is missing 'override' specifier.
// TypeError: (64-91): Overriding function changes state mutability from "nonpayable" to "view".