solidity/test/libsolidity/syntaxTests/constructor/inconstructible_internal_constructor.sol

9 lines
194 B
Solidity
Raw Normal View History

2018-04-17 09:39:40 +00:00
contract C {
constructor() internal {}
}
contract D {
function f() public { C c = new C(); c; }
}
// ----
// TypeError: (84-89): Contract with internal constructor cannot be created directly.