From aa95e9e98618d8838ba6d83f3cc365113ca6f410 Mon Sep 17 00:00:00 2001 From: Jesus Fernandez Date: Tue, 5 Sep 2017 09:49:55 +0200 Subject: Fix zero-as-null-pointer-constant warning in QObject MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Change-Id: Icf0c836b96cd750edeee71c144e2bd9917a96815 Reviewed-by: Mårten Nordheim Reviewed-by: Thiago Macieira Reviewed-by: Jędrzej Nowacki --- src/corelib/kernel/qobject_p.h | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'src/corelib/kernel') diff --git a/src/corelib/kernel/qobject_p.h b/src/corelib/kernel/qobject_p.h index ad88bcf274..ddae349528 100644 --- a/src/corelib/kernel/qobject_p.h +++ b/src/corelib/kernel/qobject_p.h @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2016 The Qt Company Ltd. +** Copyright (C) 2017 The Qt Company Ltd. ** Copyright (C) 2013 Olivier Goffart ** Contact: https://www.qt.io/licensing/ ** @@ -145,7 +145,7 @@ public: ushort connectionType : 3; // 0 == auto, 1 == direct, 2 == queued, 4 == blocking ushort isSlotObject : 1; ushort ownArgumentTypes : 1; - Connection() : nextConnectionList(0), ref_(2), ownArgumentTypes(true) { + Connection() : nextConnectionList(nullptr), ref_(2), ownArgumentTypes(true) { //ref_ is 2 for the use in the internal lists, and for the use in QMetaObject::Connection } ~Connection(); @@ -160,7 +160,7 @@ public: }; // ConnectionList is a singly-linked list struct ConnectionList { - ConnectionList() : first(0), last(0) {} + ConnectionList() : first(nullptr), last(nullptr) {} Connection *first; Connection *last; }; @@ -200,7 +200,7 @@ public: } static const QObjectPrivate *get(const QObject *o) { return o->d_func(); } - int signalIndex(const char *signalName, const QMetaObject **meta = 0) const; + int signalIndex(const char *signalName, const QMetaObject **meta = nullptr) const; inline bool isSignalConnected(uint signalIdx, bool checkDeclarative = true) const; inline bool isDeclarativeSignalConnected(uint signalIdx) const; @@ -376,12 +376,12 @@ class Q_CORE_EXPORT QMetaCallEvent : public QEvent { public: QMetaCallEvent(ushort method_offset, ushort method_relative, QObjectPrivate::StaticMetaCallFunction callFunction , const QObject *sender, int signalId, - int nargs = 0, int *types = 0, void **args = 0, QSemaphore *semaphore = 0); + int nargs = 0, int *types = nullptr, void **args = nullptr, QSemaphore *semaphore = nullptr); /*! \internal \a signalId is in the signal index range (see QObjectPrivate::signalIndex()). */ QMetaCallEvent(QtPrivate::QSlotObjectBase *slotObj, const QObject *sender, int signalId, - int nargs = 0, int *types = 0, void **args = 0, QSemaphore *semaphore = 0); + int nargs = 0, int *types = nullptr, void **args = nullptr, QSemaphore *semaphore = nullptr); ~QMetaCallEvent(); -- cgit v1.2.3