3 ms·
The first point is kind of silly: You can make rust-style constructor functions if you want, and have a private constructor to enforce the behavior. Although i
by timw4mail 3y ago
The first point is kind of silly: You can make rust-style constructor functions if you want, and have a private constructor to enforce the behavior.
Although it does require some boilerplate, which may seem like pointless extra work.
- alfredbez 3y agoI think this was not the point, see: > [...] only to realise there the class has a private constructor or that there are static constructors which I should be using [...]