2 ms·
Throwing in constructors is an anti-pattern imo but assuming you need it, how does go solve this? Would you not return nil and an error that you would immediat
by jayd16 8y ago
Throwing in constructors is an anti-pattern imo but assuming you need it, how does go solve this? Would you not return nil and an error that you would immediately check? Seems like defensively checking return values in go isn't that much better than catching every exception.
Maybe I don't understand the correct go implementation.