solidity/test/libsolidity/syntaxTests/inheritance/wrong_type_base_arguments.sol
2019-03-11 16:15:18 +01:00

10 lines
331 B
Solidity

contract Base {
constructor(uint8) public {}
}
contract Derived is Base(300) { }
contract Derived2 is Base {
constructor() Base(2) public { }
}
// ----
// TypeError: (74-77): Invalid type for argument in constructor call. Invalid implicit conversion from int_const 300 to uint8 requested. Literal is too large to fit in uint8.