Qt 6.x
The Qt SDK
Loading...
Searching...
No Matches
qexceptionhandling.h File Reference
#include <QtCore/qtconfigmacros.h>
#include <QtCore/qcompilerdetection.h>
#include <QtCore/qtcoreexports.h>
+ Include dependency graph for qexceptionhandling.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define QT_TRY   try
 
#define QT_CATCH(A)   catch (A)
 
#define QT_THROW(A)   throw A
 
#define QT_RETHROW   throw
 
#define QT_TERMINATE_ON_EXCEPTION(expr)   do { try { expr; } catch (...) { qTerminate(); } } while (false)
 

Functions

QT_BEGIN_NAMESPACE Q_NORETURN Q_DECL_COLD_FUNCTION Q_CORE_EXPORT void qTerminate () noexcept
 

Macro Definition Documentation

◆ QT_CATCH

#define QT_CATCH (   A)    catch (A)

Definition at line 34 of file qexceptionhandling.h.

◆ QT_RETHROW

#define QT_RETHROW   throw

Definition at line 36 of file qexceptionhandling.h.

◆ QT_TERMINATE_ON_EXCEPTION

#define QT_TERMINATE_ON_EXCEPTION (   expr)    do { try { expr; } catch (...) { qTerminate(); } } while (false)

Definition at line 40 of file qexceptionhandling.h.

◆ QT_THROW

#define QT_THROW (   A)    throw A

Definition at line 35 of file qexceptionhandling.h.

◆ QT_TRY

#define QT_TRY   try

Definition at line 33 of file qexceptionhandling.h.

Function Documentation

◆ qTerminate()

QT_BEGIN_NAMESPACE Q_NORETURN Q_DECL_COLD_FUNCTION Q_CORE_EXPORT void qTerminate ( )
noexcept

Definition at line 15 of file qexceptionhandling.cpp.

Referenced by QTest::setFailed().

+ Here is the caller graph for this function: