diff --git a/src/corelib/thread/qexception.cpp b/src/corelib/thread/qexception.cpp index fd98505282e..9e3d148491e 100644 --- a/src/corelib/thread/qexception.cpp +++ b/src/corelib/thread/qexception.cpp @@ -82,10 +82,37 @@ QT_BEGIN_NAMESPACE \internal */ +/*! + Destroys this QException object. +*/ QException::~QException() noexcept { } +/*! + \fn QException::QException() + + Constructs a QException object. +*/ + +/*! + \fn QException::QException(const QException &other) + + Creates a copy of \a other. + + \note Be careful when using this function, as you risk slicing. + + \sa clone() +*/ + +/*! + \fn QException &QException::operator=(const QException &other) + + Copy-assigns \a other over this object. + + \note Be careful when using this function, as you risk slicing. +*/ + void QException::raise() const { QException e = *this; diff --git a/src/corelib/thread/qexception.h b/src/corelib/thread/qexception.h index 62b9e70bea4..e5c62873509 100644 --- a/src/corelib/thread/qexception.h +++ b/src/corelib/thread/qexception.h @@ -21,7 +21,10 @@ QT_BEGIN_NAMESPACE class Q_CORE_EXPORT QException : public std::exception { public: + QException() = default; ~QException() noexcept; + QException(const QException &) = default; + QException &operator=(const QException &) = default; virtual void raise() const; virtual QException *clone() const; };