From bda2169d965a40b3229421154979526448a1f745 Mon Sep 17 00:00:00 2001 From: Christian Ehrlicher Date: Mon, 25 Nov 2019 20:31:38 +0100 Subject: Doc: remove documented macros which were removed in Qt5 Remove documentation about QMIN, QMAX and QABS - they were removed during Qt4 -> 5 porting. Change-Id: I24e12e4f2bba635ff412e73dd1d0134bbab5247a Reviewed-by: Paul Wicking --- src/corelib/global/qglobal.cpp | 30 ------------------------------ 1 file changed, 30 deletions(-) (limited to 'src/corelib/global') diff --git a/src/corelib/global/qglobal.cpp b/src/corelib/global/qglobal.cpp index b662233d4e..c145c46f78 100644 --- a/src/corelib/global/qglobal.cpp +++ b/src/corelib/global/qglobal.cpp @@ -4134,36 +4134,6 @@ bool qunsetenv(const char *varName) directive. */ -/*! - \macro QABS(n) - \relates - \obsolete - - Use qAbs(\a n) instead. - - \sa QMIN(), QMAX() -*/ - -/*! - \macro QMIN(x, y) - \relates - \obsolete - - Use qMin(\a x, \a y) instead. - - \sa QMAX(), QABS() -*/ - -/*! - \macro QMAX(x, y) - \relates - \obsolete - - Use qMax(\a x, \a y) instead. - - \sa QMIN(), QABS() -*/ - /*! \macro const char *qPrintable(const QString &str) \relates -- cgit v1.2.3 From caa82e1fc24907af0a81e31cf9b77ae8e82e44cc Mon Sep 17 00:00:00 2001 From: Paul Wicking Date: Wed, 18 Dec 2019 15:27:06 +0100 Subject: Doc: Add since version for QCursor::swap and QOperatingSystemVersion::currentType. Fixes: QTBUG-80854 Fixes: QTBUG-80891 Change-Id: Ia256fa0d3ad4665f44b933f5a4a8d4ee87e9fc13 Reviewed-by: Timur Pocheptsov Reviewed-by: Leena Miettinen --- src/corelib/global/qoperatingsystemversion.cpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src/corelib/global') diff --git a/src/corelib/global/qoperatingsystemversion.cpp b/src/corelib/global/qoperatingsystemversion.cpp index 33793ca168..261f5c8795 100644 --- a/src/corelib/global/qoperatingsystemversion.cpp +++ b/src/corelib/global/qoperatingsystemversion.cpp @@ -299,6 +299,8 @@ int QOperatingSystemVersion::compare(const QOperatingSystemVersion &v1, Returns the current OS type without constructing a QOperatingSystemVersion instance. + \since 5.10 + \sa current() */ -- cgit v1.2.3 From 512b87bc28fc70058e240cf720fdfc9c9da98afb Mon Sep 17 00:00:00 2001 From: Albert Astals Cid Date: Wed, 18 Dec 2019 09:32:31 +0100 Subject: Don't have a "see also qrand" from qrand I guess what we wanted there was qsrand Change-Id: I8e18e76ae65abf9de231d51faa61cc9142ea2b98 Reviewed-by: Thiago Macieira --- src/corelib/global/qrandom.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/corelib/global') diff --git a/src/corelib/global/qrandom.cpp b/src/corelib/global/qrandom.cpp index 3cbd40b772..10672c1f92 100644 --- a/src/corelib/global/qrandom.cpp +++ b/src/corelib/global/qrandom.cpp @@ -1295,7 +1295,7 @@ void qsrand(uint seed) \note This function is deprecated. In new applications, use QRandomGenerator instead. - \sa qrand(), QRandomGenerator + \sa qsrand(), QRandomGenerator */ int qrand() { -- cgit v1.2.3 From c24404dbda48bd4f9d6ceb4777fced7b164345fd Mon Sep 17 00:00:00 2001 From: Friedemann Kleint Date: Thu, 19 Dec 2019 10:10:43 +0100 Subject: Unbreak developer build with clang-cl Move the macro definitions for Q_DECL_UNUSED_MEMBER along with a definition for Q_DECL_UNUSED from the scope excluding icc and cl into a separate one for plain clang and cl since the attributes work with clang-cl as well. Remove the check introduced in 9782938045c33b37fe0bbb6cdf00e406cd3d837e since it is assumed that all clang versions have the attribute now. Fixes: include\QtCore/../../src/corelib/io/qloggingcategory.h(87,32): error: private field 'd' is not used [-Werror,-Wunused-private-field] Q_DECL_UNUSED_MEMBER void *d; // reserved for future use ^ include\QtCore/../../src/corelib/io/qloggingcategory.h(108,31): error: private field 'placeholder' is not used [-Werror,-Wunused-private-field] Q_DECL_UNUSED_MEMBER bool placeholder[4]; // reserved for future use Task-number: QTBUG-63512 Change-Id: I651771b085408443bb02e96698a980170fcaeb6d Reviewed-by: Thiago Macieira --- src/corelib/global/qcompilerdetection.h | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) (limited to 'src/corelib/global') diff --git a/src/corelib/global/qcompilerdetection.h b/src/corelib/global/qcompilerdetection.h index 60dc7ce688..0091cfcb60 100644 --- a/src/corelib/global/qcompilerdetection.h +++ b/src/corelib/global/qcompilerdetection.h @@ -828,13 +828,14 @@ # endif # endif -# if defined(__has_warning) -# if __has_warning("-Wunused-private-field") -# define Q_DECL_UNUSED_MEMBER Q_DECL_UNUSED -# endif -# endif +#endif // Q_CC_CLANG && !Q_CC_INTEL && !Q_CC_MSVC -#endif // Q_CC_CLANG +#if defined(Q_CC_CLANG) && !defined(Q_CC_INTEL) +# ifndef Q_DECL_UNUSED +# define Q_DECL_UNUSED __attribute__((__unused__)) +# endif +# define Q_DECL_UNUSED_MEMBER Q_DECL_UNUSED +#endif #if defined(Q_CC_GNU) && !defined(Q_CC_INTEL) && !defined(Q_CC_CLANG) # define Q_COMPILER_RESTRICTED_VLA -- cgit v1.2.3