The exception has more overhead, so there is a performance problem, especially when you can expect that it will most likely be selected often, as is the case with save .
Fewer lines of code checks to see if the return value is false than the crash exception, so I don't see how this is a problem with checking the return value if you already need to save the exception. How often is the exception thrown by save! ever had to pick up a call stack in practice? Rarely, if ever, in my experience.
If, when calling save an exception exists, not save! , you need it to display a page with an error of 500 because what happened is what happened: an error that has not been repaired is unknown and unexpected.
Andrew Marshall Feb 20 '11 at 10:27 2011-02-20 10:27
source share