[Development] Disabling exception support in QtCore?
Thiago Macieira
thiago.macieira at intel.com
Wed Oct 2 00:41:56 CEST 2013
On quarta-feira, 2 de outubro de 2013 00:04:58, Christoph Feck wrote:
> On Tuesday 01 October 2013 21:20:29 Thiago Macieira wrote:
> > Since we decided to roll back support for exceptions in our
> > container classes, the only thing that currently needs exception
> > support is the mainloop allowing std::bad_alloc through.
> >
> > Is it worth it?
> >
> > Should we disable exceptions in QtCore?
>
> If it allows us to get a backtrace actually showing where the
> unhandled exception was thrown (instead of saying it was caused by the
> Qt event loop), I am all for disabling exception support in QtCore.
In order to properly do that, we should remove all try/catch blocks in QtCore
and replace with scoped pointers and scoped values. We should let the
destructors handle the cleanup.
Turning exceptions off may or may not get you the backtrace. It may also get
you a std::terminate or a crash.
--
Thiago Macieira - thiago.macieira (AT) intel.com
Software Architect - Intel Open Source Technology Center
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 190 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.qt-project.org/pipermail/development/attachments/20131001/367b2c9b/attachment.sig>
More information about the Development
mailing list