Loading…
This event has ended. View the official site or create your own event → Check it out
This event has ended. Create your own
View analytic
Wednesday, September 23 • 9:00am - 10:00am
The unexceptional exceptions

Log in to save this to your schedule and see who's attending!

The main goal of this class is not to teach how to use exceptions - it's not that hard, and we will go over the basics at the start of the class. The main goal is to teach to not be afraid to use exceptions, and also not to be awed by them. We will spend few minutes on the basic syntax and semantics of exceptions, as well as their interaction with other parts of the language. Then we get to the real issue: the error handling. It is important to understand that errors, or exceptional cases, do not need to be handled by exceptions. Exceptions are just a tool that provides one way of coding the error handling, and it’s not even a very good one: overly focusing on exception handling, as opposed to error handling, often leads to code that is both buggy and hard to read and maintain. My goal is to show that the best approach to error handling involves very light explicit use of exceptions. The emphasis is put on maintaining program invariants and avoiding the undefined behavior, something all programs need to do at all times, with or without errors. Thus, a well-written program should have very little error handling code, and only a part of that explicitly deals with exceptions. This understanding is particularly important for programmers who have to deal with the “we don’t use exceptions here” mindset, or want to use exceptions for handling errors in their part of the larger legacy system. Once you understand (small) the role exceptions play in the real problem of error handling, it becomes quite obvious how to start using exceptions in a small part of a larger system without disturbing the rest of it, or even how to write very “exception-like” code without actually using exceptions. Most importantly, the exceptions are completely demystified.

Speakers
avatar for Fedor Pikus

Fedor Pikus

Chief Engineering Scientist, Mentor Graphics
Fedor G Pikus is a Chief Engineering Scientist in the Design to Silicon division of Mentor Graphics Corp. His earlier positions included a Senior Software Engineer at Google and a Chief Software Architect for Calibre PERC, LVS, DFM at Mentor Graphics. He joined Mentor Graphics in 1998 when he made a switch from academic research in computational physics to software industry. His responsibilities as a Chief Scientist include planning long-term... Read More →


Wednesday September 23, 2015 9:00am - 10:00am
Six (406) Meydenbauer Center