By Roger Orr
A large number of articles and books on programming provide sample code, which all too often is either totally silent about errors or contains a comment such as / error handling omitted for brevity /. While this may be fine for simple examples, it doesn’t work so well for actual real-world programs where all sorts of things can go wrong and the program is expected to cope.
In this presentation I’ll look at some techniques for handling errors and we’ll look at their strength and weaknesses and also some pointers on how to combine different error handling techniques.
Should error handling be local or non-local? How do you test error handling? Can you reduce the likelihood, and impact, of errors?
While many of the examples will use C++ code many of the design principles are applicable more widely.










