What are the differences between MFC Exception macros and
C++ exception keywords?
Answers were Sorted based on User's Feedback
Answer / hemalatha
The main difference between the macros and the keywords is
that the macros "automatically" delete a caught exception
when the exception goes out of scope. Code using the
keywords does not; exceptions caught in a catch block must
be explicitly deleted. Mixing macros and C++ exception
keywords can cause memory leaks when an exception object is
not deleted, or heap corruption when an exception is
deleted twice.
| Is This Answer Correct ? | 3 Yes | 0 No |
Answer / mullaikani
Class macros — TRY, CATCH, THROW, and so on — to use the C++
exception-handling keywords try, catch, and throw.
The major difference between the macros and the keywords is
that code using the macros "automatically" deletes a caught
exception when the exception goes out of scope. Code using
the keywords does not, so you must explicitly delete a
caught exception.
| Is This Answer Correct ? | 2 Yes | 1 No |
how does conditionally close the Dialog Box ?
If there is more than 100 control in a window how we can change the Taborder of a controls
what message is sent to an application when the user presses the primary button?
What is mfc class hierarchy?
What is document-view architecture ? Give me one real time example for SDI ?
Hi All, i am new for VC++ SDK. i want to get the IP Address of all the External device connected with my local machine.please give the code Regards, Praveer
What is the difference between ASSERT and VERIFY?
Explain in sort What is CTargetObject?
What view class enables you to use an edit control as a view?
How can i implement the dynamic menus in MFC plz give the code
What is the difference between GetMessage and PeekMessage ?
if both base and derived class have the constructors if i create an object for derive class which class constructor is executed first