Remix tells me: Constructor must be public or internal
If i make internal I get: This contract does not implement all functions and thus cannot be created. ...
What's the purpose and how to use an internal constructor ?
Why must a constructor be public instead of external?
See #2638. Basically it allows an abstract contract to have a constructor, which is used by the child.
Thanks, that's helpful and makes sense.
Any explanation for:
Why must a constructor be public instead of external?
Idea-wise, if a constructor was allowed to be external then that would prevent inheritance? (There's an issue here somewhere like final in Java.)
Hm, I cannot recall any particular reason, but yes, inheritance would be a problem with external constructors.
@ethers would you be interested in documenting the above in the main docs? This question comes up a few times, good have it explained.
@axic I can pick this up if @ethers hasn't yet?
@elenadimitrova yes, please take it, it would be great having this document. @ethers has not expressed interest, it is safe to assume he hasn't started working on it.
Is this the best place in the documentation for that @axic
http://solidity.readthedocs.io/en/develop/contracts.html#abstract-contracts
Shall we roll in #627 here as well?
@elenadimitrova I think it would make sense introducing a new section for constructors somewhere in the Inheritance section.
@elenadimitrova Thanks for documenting the reason for internal constructors.