On 13.11.2015 00:15, Matthew Woehlke wrote:
On 2015-11-12 15:56, Igor Mironchik wrote:
Can you, please, explain why allocating memory when throwing exception
is bad practice? Or just can you give a link on any article about this
question.... Thank you.
What if the exception occurred because you are out of memory?

Then will be std::bad_alloc instead of my custom exception. Am I right?

Then if I will catch std::bad_alloc somewhere and correctly will do cleanup and stop, for example, then there will not be problems. Right?

--
Best Regards,
Igor Mironchik.

_______________________________________________
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest

Reply via email to