4 ms·
> Only when exceptions are thrown, or also during the happy path? This is where I want to make a key distinction between exceptions and errors ala Railway prog
by steego 8y ago
> Only when exceptions are thrown, or also during the happy path?
This is where I want to make a key distinction between exceptions and errors ala Railway programming. Performance with exceptions doesn't really matter because exceptions are supposed to be exceptional.
With Railway oriented programmer, the whole point is that you're encoding errors into the logic of some type of system. These types of errors may not only be not exceptional, they may a very regular part of the application.
Like I told another commenter, a friend of mine uses them in an application where they easily would throw thousands of exceptions per second if they used exceptions. Not only would it undermine the performance of their system, it's using the wrong tool for the job.