summaryrefslogtreecommitdiffstats
path: root/src/corelib/thread
diff options
context:
space:
mode:
authorStephen Kelly <stephen.kelly@kdab.com>2013-06-15 11:49:45 +0200
committerThe Qt Project <gerrit-noreply@qt-project.org>2013-06-17 09:44:22 +0200
commitd9fb6e6dbb2b322556d581265da2442e3b91a6a3 (patch)
tree8d5ae465adf4db8468c7e0ff1d91113594cb45aa /src/corelib/thread
parentd9e722d8560c07adb1852cfd061ffb23197d06fd (diff)
Remove use of 'register' from Qt.
It is deprecated and clang is starting to warn about it. Patch mostly generated by clang itself, with some careful grep and sed for the platform-specific parts. Change-Id: I8058e6db0f1b41b33a9e8f17a712739159982450 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'src/corelib/thread')
-rw-r--r--src/corelib/thread/qgenericatomic.h4
-rw-r--r--src/corelib/thread/qmutex.cpp2
2 files changed, 3 insertions, 3 deletions
diff --git a/src/corelib/thread/qgenericatomic.h b/src/corelib/thread/qgenericatomic.h
index a0a851eabb..3a213f6a25 100644
--- a/src/corelib/thread/qgenericatomic.h
+++ b/src/corelib/thread/qgenericatomic.h
@@ -172,7 +172,7 @@ template <typename BaseClass> struct QGenericAtomicOps
{
// implement fetchAndStore on top of testAndSet
Q_FOREVER {
- register T tmp = load(_q_value);
+ T tmp = load(_q_value);
if (BaseClass::testAndSetRelaxed(_q_value, tmp, newValue))
return tmp;
}
@@ -207,7 +207,7 @@ template <typename BaseClass> struct QGenericAtomicOps
{
// implement fetchAndAdd on top of testAndSet
Q_FOREVER {
- register T tmp = BaseClass::load(_q_value);
+ T tmp = BaseClass::load(_q_value);
if (BaseClass::testAndSetRelaxed(_q_value, tmp, T(tmp + valueToAdd)))
return tmp;
}
diff --git a/src/corelib/thread/qmutex.cpp b/src/corelib/thread/qmutex.cpp
index 1ed4a77950..378813c889 100644
--- a/src/corelib/thread/qmutex.cpp
+++ b/src/corelib/thread/qmutex.cpp
@@ -59,7 +59,7 @@ QT_BEGIN_NAMESPACE
static inline bool isRecursive(QMutexData *d)
{
- register quintptr u = quintptr(d);
+ quintptr u = quintptr(d);
if (Q_LIKELY(u <= 0x3))
return false;
#ifdef QT_LINUX_FUTEX