[Development] Disabling exception support in QtCore?

Knoll Lars Lars.Knoll at digia.com
Wed Oct 2 07:42:24 CEST 2013


On 01.10.13 23:23, "Thiago Macieira" <thiago.macieira at intel.com> wrote:

>On terça-feira, 1 de outubro de 2013 20:00:56, Knoll Lars wrote:
>> Yes, signal/slot connections between user code should IMO still be able
>>to
>> pass through exceptions. I am afraid removing that will break code
>>that's
>> out there.
>
>This is already forbidden since 5.0.

Is there any good reason why we don't support this, as we did in Qt 4? My
goal of still compiling Qt Core with exceptions enabled was to allow for
exactly this use case.

Lars

>
>You can throw from your slots, if you want. If you call them directly,
>you're 
>responsible for catching the exception.
>
>However, it's undefined behaviour if you let the exception go back to
>QtCore 
>code. The *best* you can hope for is that std::terminate is called.
>
>-- 
>Thiago Macieira - thiago.macieira (AT) intel.com
>  Software Architect - Intel Open Source Technology Center




More information about the Development mailing list