3 ms·
I don't see why anyone would find this superior to a stack trace.
by gozur88 10y ago
I don't see why anyone would find this superior to a stack trace.
- idobai 10y agoBecause you need to handle errors properly and not let them sneak into production - there is only a few amount of languages which uses exceptions for eh and they're really suffering from it(ex. Java). Throwing exceptions are a lazy and expensive way for eh. It's far better to write code which notifies the user about the possible output in your API - Option is for when you can't always provide a result and Either is for when various errors could happen. It's really a lame architecture when you need to find exceptions in the logs and talk about it for the modules' developers because some of the exceptions "are OK" - genuine java ee strategy.