summaryrefslogtreecommitdiffstats
path: root/src/corelib/kernel
diff options
context:
space:
mode:
authorAaron Kennedy <aaron.kennedy@nokia.com>2010-04-07 00:06:28 (GMT)
committerAaron Kennedy <aaron.kennedy@nokia.com>2010-04-07 00:06:28 (GMT)
commitca4bc7c16bdf27855a13b15dbabd8019ab2bef24 (patch)
treec15bc918bd87994d83b87ef922da9cc17253d92d /src/corelib/kernel
parent739c1c6a4322c0d48afd2a24e3dc2156fee577e1 (diff)
parent71a328397720af7229fd6ee48acaa19f7339a8de (diff)
downloadQt-ca4bc7c16bdf27855a13b15dbabd8019ab2bef24.zip
Qt-ca4bc7c16bdf27855a13b15dbabd8019ab2bef24.tar.gz
Qt-ca4bc7c16bdf27855a13b15dbabd8019ab2bef24.tar.bz2
Merge branch '4.7' of scm.dev.nokia.troll.no:qt/qt-qml into 4.7
Diffstat (limited to 'src/corelib/kernel')
-rw-r--r--src/corelib/kernel/qmetaobject_p.h7
-rw-r--r--src/corelib/kernel/qobject.cpp2
2 files changed, 6 insertions, 3 deletions
diff --git a/src/corelib/kernel/qmetaobject_p.h b/src/corelib/kernel/qmetaobject_p.h
index a176149..b538787 100644
--- a/src/corelib/kernel/qmetaobject_p.h
+++ b/src/corelib/kernel/qmetaobject_p.h
@@ -196,7 +196,7 @@ static QByteArray normalizeTypeInternal(const char *t, const char *e, bool fixSc
if (*(e-1) == '&') { // treat const reference as value
t += 6;
--e;
- } else if (is_ident_char(*(e-1))) { // treat const value as value
+ } else if (is_ident_char(*(e-1)) || *(e-1) == '>') { // treat const value as value
t += 6;
}
}
@@ -287,13 +287,16 @@ static QByteArray normalizeTypeInternal(const char *t, const char *e, bool fixSc
}
// cv qualifers can appear after the type as well
- if (t != e && (e - t >= 5 && strncmp("const", t, 5) == 0)) {
+ if (!is_ident_char(c) && t != e && (e - t >= 5 && strncmp("const", t, 5) == 0)
+ && (e - t == 5 || !is_ident_char(t[5]))) {
t += 5;
while (t != e && is_space(*t))
++t;
if (adjustConst && t != e && *t == '&') {
// treat const ref as value
++t;
+ } else if (adjustConst && !star) {
+ // treat const as value
} else if (!star) {
// move const to the front (but not if const comes after a *)
result.prepend("const ");
diff --git a/src/corelib/kernel/qobject.cpp b/src/corelib/kernel/qobject.cpp
index dfd6a08..411f22e 100644
--- a/src/corelib/kernel/qobject.cpp
+++ b/src/corelib/kernel/qobject.cpp
@@ -1472,7 +1472,7 @@ void QObject::moveToThread(QThread *targetThread)
} else if (d->threadData != currentData) {
qWarning("QObject::moveToThread: Current thread (%p) is not the object's thread (%p).\n"
"Cannot move to target thread (%p)\n",
- d->threadData->thread, currentData->thread, targetData->thread);
+ currentData->thread, d->threadData->thread, targetData->thread);
#ifdef Q_WS_MAC
qWarning("On Mac OS X, you might be loading two sets of Qt binaries into the same process. "