Login | Register   
LinkedIn
Google+
Twitter
RSS Feed
Download our iPhone app
TODAY'S HEADLINES  |   ARTICLE ARCHIVE  |   FORUMS  |   TIP BANK
Browse DevX
Sign up for e-mail newsletters from DevX


Tip of the Day
Language: C++
Expertise: Beginner
Nov 5, 1999

Structured Exception Handling and Standard Exception Handling

Many C compilers provide a non-standard feature called "structured exception handling", or SEH for short. SEH can trap asynchronous, platform-specific exceptions such as division by zero, floating point overflow and underflow, and other hardware exceptions. In contrast, the standard C++ exception handling (EH) applies only to synchronous exceptions, i.e., exceptions that are generated by the program itself, and which are explicitly created by a throw statement.

The type of exceptions raised by SEH and EH, as well as their underlying mechanisms and recovery methods, are incompatible. Therefore, never confuse SEH with EH, or vice versa. In C, use SEH if necessary. In C++, stick to EH exclusively.

Danny Kalev
 
Comment and Contribute

 

 

 

 

 


(Maximum characters: 1200). You have 1200 characters left.

 

 

Sitemap
Thanks for your registration, follow us on our social networks to keep up-to-date