solidity/test/libsolidity/syntaxTests/inheritance/fallback_receive/receive_parameter.sol
2022-04-01 23:41:18 -05:00

13 lines
617 B
Solidity

contract C {
receive(bytes2) {}
}
contract D is C {
receive() {}
}
// ----
// SyntaxError 4937: (17-35='receive(bytes2) {}'): No visibility specified. Did you intend to add "external"?
// SyntaxError 4937: (60-72='receive() {}'): No visibility specified. Did you intend to add "external"?
// DeclarationError 7793: (17-35='receive(bytes2) {}'): Receive ether function must be payable, but is "nonpayable".
// DeclarationError 4095: (17-35='receive(bytes2) {}'): Receive ether function must be defined as "external".
// DeclarationError 6857: (24-32='(bytes2)'): Receive ether function cannot take parameters.