solidity/test/libsolidity/syntaxTests/constructor/function_named_constructor.sol
2022-04-01 23:41:18 -05:00

6 lines
292 B
Solidity

contract C {
function constructor();
}
// ----
// ParserError 3323: (26-37='constructor'): This function is named "constructor" but is not the constructor of the contract. If you intend this to be a constructor, use "constructor(...) { ... }" without the "function" keyword to define it.