Entries:
Comments:
Posts:

Loading User Information from Channel 9

Something went wrong getting user information from Channel 9

Latest Achievement:

Loading User Information from MSDN

Something went wrong getting user information from MSDN

Visual Studio Achievements

Latest Achievement:

Loading Visual Studio Achievements

Something went wrong getting the Visual Studio Achievements

Ale Contenti and Louis Lafreniere: Understanding Exceptions and When/How to Handle Them

Download

Right click “Save as…”

Embed code for this video

Copy the code above to embed our video on your website/blog.

Close

Video format

Note: These selections will fall back to the next best format depending upon browser capability.

Close
Sometimes, things go wrong when code executes. You can't predict when this will happen or even why, but you can write code to handle exceptional problems. If you're lucky, the problem will carry with it a bunch of useful information that you can use, at runtime, to handle the specific error. These exceptional information structures are called structured exceptions; blobs of bad news carrying useful and specific information that you can use to find your way out of the exceptional rabbit hole. Of course, with useful data packaged up in an exception you can more easily debug to find root causes, which is much harder to do with, say, error codes...

What is a structured exception, exactly? How should you handle exceptions that you don't assume will arise during the execution of your code? What are the correct patterns of exception handling that you can safely rely on? What does the C++ compiler have to do with exception code patterns?

Come along for ride into the deep and murky world of exceptions with some folks that truly understand them at the most fundamental levels.

Ale Contenti is a senior development lead in the C++ base class libraries team. Louis Lafreniere is a principal software developer in the C++ compiler group. Here, Ale and Louis teach us about exceptions and handling them (and when not to handle them). I love talking to the VC++ People. They live on the metal and really understand the fascinating intracacies of our platform.

Enjoy this latest Going Deep episode.

Tags:

Comments Closed

Comments have been closed since this content was published more than 30 days ago, but if you'd like to continue the conversation, please create a new thread in our Forums,
or Contact Us and let us know.