From f8710c79adc55708a6484a0dcd3ce3d0ddd57284 Mon Sep 17 00:00:00 2001 From: Harald Fernengel Date: Wed, 19 Aug 2009 13:33:32 +0200 Subject: Cosmetic fix: Unify the Q_DISABLE_COPY macro Q_DISABLE_COPY must make the copy constructor and assignment operator private in all cases, otherwise the compiler will create implicit versions when exception support is on. --- src/corelib/global/qglobal.h | 13 +++---------- 1 file changed, 3 insertions(+), 10 deletions(-) diff --git a/src/corelib/global/qglobal.h b/src/corelib/global/qglobal.h index f38d7cc..6722418 100644 --- a/src/corelib/global/qglobal.h +++ b/src/corelib/global/qglobal.h @@ -2337,16 +2337,9 @@ Q_CORE_EXPORT QString qtTrId(const char *id, int n = -1); classes contains a private copy constructor and assignment operator to disable copying (the compiler gives an error message). */ - -#if !defined(Q_NO_DECLARED_NOT_DEFINED) || !defined(QT_MAKEDLL) -# define Q_DISABLE_COPY(Class) \ - Class(const Class &); \ - Class &operator=(const Class &); -#else -# define Q_DISABLE_COPY(Class) \ - Class(const Class &); \ - Class &operator=(const Class &); -#endif +#define Q_DISABLE_COPY(Class) \ + Class(const Class &); \ + Class &operator=(const Class &); class QByteArray; Q_CORE_EXPORT QByteArray qgetenv(const char *varName); -- cgit v0.12