4 ms·
Valid critique in legacy sense, the class syntax of course mitigates much of it. But why would you want to delegate constructors?
by eurasiantiger 5y ago
Valid critique in legacy sense, the class syntax of course mitigates much of it. But why would you want to delegate constructors?
- masklinn 5y ago> But why would you want to delegate constructors? Because if you inherit from something you probably want to run the super object's constructor so that yours is fully initialised?
- eurasiantiger 4y agoAh, so you mean calling the superclass constructor. To me, the wording ”delegate a constructor” means ”to entirely shift responsibility for constructing an instance to something that isn’t the actual constructor”, which made me think of something else than the normal way extending constructors work.