Hacker News new | past | comments | ask | show | jobs | submit login

I really think how you are using the language had a large effect on how you are going to view all this. If you are building a commandline utility then the way go deals with errors is great you just panic and send back a message. If you are building a long running web service you want a whole lot more info to go into your logs for when things go wrong. I dunno what the solution is but try/catch doesn’t seem to be the right thing to focus on.



Despite the name, there's really nothing in common with try/catch. It's just sugar for if err != nil { return }.


Try is a terrible choice for a name exactly because of try/catch, I don't know why they decided on that.




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: